give an example of type casting by a simple c program

Answers were Sorted based on User's Feedback



give an example of type casting by a simple c program..

Answer / guest

[code]
#include<stdio.h>
main()
{
float a;
a = (float)15 / 3;
printf("%f\n",a);
}
[/code]

Is This Answer Correct ?    7 Yes 4 No

give an example of type casting by a simple c program..

Answer / ola

#include<stdio.h>
void main()
{
float a;
a = (float)15 / 3;
printf("%f\n",a);
}

Is This Answer Correct ?    4 Yes 4 No

Post New Answer

More C Interview Questions

What is the difference between a string and an array?

0 Answers  


What is the o/p of the follow pgm? #include<stdio.h> main() { char char_arr[5]=”ORACL”; char c=’E’; prinf(“%s\n”,strcat(char_arr,c)); } a:oracle b. oracl c.e d.none

2 Answers   Oracle,


What is bash c?

0 Answers  


string reverse using recursion

0 Answers   Mind Tree,


progrem to generate the following series 1 12 123 1234 12345

6 Answers   HCL, Wipro,






Derive the complexity expression for AVL tree?

1 Answers  


Write a program to write a given string in maximum possibilities? i.e str[5]="reddy"; i.e we can write this string in 120 ways for that write a program

3 Answers   Subex,


define c

6 Answers   HCL, TCS,


Why are some ANSI/ISO Standard library routines showing up as undefined, even though I've got an ANSI compiler?

0 Answers   Celstream,


SRUCTURE PROGRAMMING

3 Answers   CTS, Wipro,


1.int a=10; 2.int b=20; 3. //write here 4.b=30; Write code at line 3 so that when the value of b is changed variable a should automatically change with same value as b. 5.

0 Answers  


Explain is it better to use a pointer to navigate an array of values, or is it better to use a subscripted array name?

0 Answers  


Categories