Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
| Program-17 | Program to check whether the given number is prefect or not |
| Program-18 | Program to check given number is Armstrong or not |
| Program-19 | Program to find power of a given number |
| Program-20 | Program to convert datatype explicitly |
| Program-21 | Program to check whether the given number is prime or not |
| Program-22 | Program to find GCD and LCM of given two number |
| Program-23 | Program to find number of digits in a given number |
Expand Down
24 changes: 18 additions & 6 deletions program-20/program.c
Original file line number Diff line number Diff line change
@@ -1,8 +1,20 @@
#include<stdio.h>
void main()
{
if(printf("hello world\n"))
{
#include <stdio.h>
#include <stdlib.h>

}
int main()
{ int a=7,b=2;
// printf("enter two number !\n");
//scanf("%d%d",&a,&b);
printf("%d",a/b);

printf("%d\n",(float)a/b);
printf("%d\n",(float)a/(float)b);
printf("%d\n",a/(float)b);

printf("%f\n",a/b);
printf("%f\n",(float)(a/b));
printf("%f\n",(float) a/b);
printf("%f\n",(float)a/(float)b);
printf("%f\n",a/(float)b);
return 0;
}