Print Friendly and PDF

Love letter in CIf you are a geek just like me and you want to impress somebody with a love letter and you don’t have an idea how to do it then you have come to the correct place.  Trust me there is no better way than to express your love for somebody better than with words. You can say something nice to her, you can take her to a romantic date, you can kiss her but that won’t last. A love letter is for eternity. It will be cherished forever and will always bring a smile to her face. I came up with an idea and the code is very simple which I will be sharing with you in a few moments. This worked amazingly for me and this post is dedicated to her. First of all you should know

What should be there in a love letter?

1. It should express your love and feelings for him/her.

2. It should be funny and remind him/her of the lovely times you had together.

3. Most importantly it should be innovative.

I will not write anything about the first two points. You will find hundreds of posts about how to write a love letter but this post is all about the third point. The love letter I wrote was made in C which made it innovative and the best part is the code is very simple to understand. You can just edit a line and make your own personalized letter or you can even modify my idea and come up with a new idea all together. But then do not forget to write your idea in the comments section.

Show the C code already:


#include<stdio.h>
#include<string.h>
void main() {
 //change the string to the words u want to say
 char *arr = "I just wanted to show u how much I missed u but didn't know how I can show you. And finally I came up with this idea when you went for dinner. I missed u a loooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooot :-*";
 int i = 0;
 printf("Type something:\n");
 while(i < strlen(arr)) {
 getch();
 printf("%c", arr[i++]);
 }
 getch();
}

This was the original message I wrote for her. Change it to the message you have for the girl/guy you want to impress.

Explain the love letter to me:

The letter is very simple. What it does is it has a string (arr) which contains the message you want to say. The integer (i) is used to print the ‘i’th character of the string (arr) till the value of ‘i’ is less than the length of the string. getch() takes in a character and doesn’t display anything and plays an important role in the program. Compile the program and send her the .exe file and wait for wonders to happen.

Hopefully you enjoyed reading this tutorial. If you have any other idea of writing technical love letters share it with me. Also if you have tried this particular technique I would love to hear the reaction you received. Use the comments section below. Thank you and visit www.intechgrity.com for more interesting tutorials and posts.

has written 11 posts

Hi, I'm a student and I'm programming in C/CPP for the the past 8years. I also have knowledge on Java, Html, JavaScript and Php. Also I'm a failed stand-up comic and will be testing my skills in this blog...:D

Comments Feed

TOP

2 Responses

Comment Now

  1. Boy, I loved this one!!!
    Must say this is a rocking awesome idea!!
    I’ll do it right away. And thanks for making the C simple.

    Ps.: I couldn’t help noticing…
    I can see how lucky you got when you say “send her the .exe file and wait for wonders to happen”
    ;) ;) ;)
    Great post!
    Cheers to you!!!
    Virneto

  2. neha sachdev says:

    i m sure that gal fell head over heels in love with you …. <3

Leave a Reply

Trackbacks/Pingbacks

Trackback URL

No trackbacks yet! If you wish, you can trackback this post from the above link