int main() {
int num1, num2;
char ch;
printf("Enter Two numbers:n");
scanf("%d %d",&num1,&num2);
printf("Function:a to add | s to subtract | m to multiply | d to divide \n");
ch = getch();
if(ch == 'a') printf("The sum is: %d", num1+num2);
if(ch == 's') printf("The subtraction result is: %d", num1-num2);
if(ch == 'm') printf("The multiplied value is: %d", num1*num2);
if(ch == 'd') printf("The result is: %d", num1/num2);
printf("\n \n \n");
}
Archives
Twitter
- Installing two versions of Netbeans. 6.8 for PHP. 6.9 for Java! 2 hours ago
- Passing time on #php room on FreeNode IRC.... 12 hours ago
- Just updated my website front page :- http://masnun.com :) 13 hours ago
- http://stackoverflow.com/questions/1285871/problem-with-ie-using-960-gs 15 hours ago
- @neotushar ID: masnun . Server: FreeNode. Usual Rooms: #codeigniter & #kohana so far :) 1 day ago
- Chatting on IRC for the first time... The place of geeks... :) 1 day ago
- Maradona lost his job! :) 1 day ago
- @djseleem Call me tomorrow. 3 days ago
- Google Search Cheat Sheet -- http://www.google.com/help/cheatsheet.html 3 days ago
- Search Google for Recursion and It will suggest Recursion back -- http://bit.ly/biO4Um :D 3 days ago
Just completed the course “Computer programming and Database management”…did the same thing in an assignment and do not like C anymore.
Good post just to pass time.
Carry on.
I don’t like C any more as well.
I love Python and PHP.