Follow Our FB Page << CircleMedia.in >> for Daily Laughter. We Post Funny, Viral, Comedy Videos, Memes, Vines...

Ramesh’s basic salary is input through the keyboard. His
dearness allowance is 40% of basic salary, and house rent
allowance is 20% of basic salary. Write a program to calculate
his gross salary.

Ramesh’s basic salary is input through the keyboard. His dearness allowance is 40% of basic s..

#include<stdio.h>
#include<conio.h>

void main()
{
int sal_amt,gro_sal;

scanf("%d",&sal_amt);

gro_sal=sal_amt+sal_amt*0.40+sal_amt*0.20;

printf("Gross salary = %d",gro_sal);
getch();
}

 Is This Answer Correct ? 0 Yes 0 No

More C Code Interview Questions

You are given any character string. Find the number of sets of vowels that come in the order of aeiou in the given string. For eg., let the given string be DIPLOMATIC. The answer returned must be "The number of sets is 2" and "The sets are "IO and AI". Vowels that form a singleton set must be neglected. Try to post the program executable in gcc or g++ or in java.

main(){ unsigned int i; for(i=1;i>-2;i--) printf("c aptitude"); }

void main() { void *v; int integer=2; int *i=&integer; v=i; printf("%d",(int*)*v); }

main() { float f=5,g=10; enum{i=10,j=20,k=50}; printf("%d\n",++k); printf("%f\n",f<<2); printf("%lf\n",f%g); printf("%lf\n",fmod(f,g)); }

#include"math.h" void main() { printf("Hi everybody"); } if <stdio.h> will be included then this program will must compile, but as we know that when we include a header file in "" then any system defined function find its defination from all the directrives. So is this code of segment will compile? If no then why?

main() { int i=_l_abc(10); printf("%d\n",--i); } int _l_abc(int i) { return(i++); }

write a program in c language to get the value of arroy keys pressed and display the message which arrow key is pressed?

Under linux environment can u please provide a c code for computing sum of series 1-2+3-4+5......n terms and -1+2-3+4-5...n terms..

main() { int i=5; printf(“%d”,i=++i ==6); }

code of a program in c language that ask a number and print its decremented and incremented number.. sample output: input number : 3 321123

Write out a function that prints out all the permutations of a string. For example, abc would give you abc, acb, bac, bca, cab, cba. You can assume that all the characters will be unique.

Write a routine to draw a circle (x ** 2 + y ** 2 = r ** 2) without making use of any floating point computations at all.

Categories
• C Code (424)
• C++ Code (128)
• VC++ Code (17)
• Java Code (84)
• Dot Net Code (114)
• Visual Basic Code (11)
• Programming Code AllOther (62)