This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include<conio.h> | |
#include<math.h> | |
void main() | |
{ | |
int i,j,k,power,a,d1,b,d2,c,d3,d,d4,e,d5; | |
for(i=0;i<=4;i++) | |
{ | |
for(j=8;j>i;j--) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<stdio.h> | |
void main() | |
{ | |
int num,i,d1,r1,d2,r2,d3,r3,d4,r4,d5,r5,d6,r6,d7,r7,d8,r8,d9,r9,octal; | |
printf("Enter the num "); | |
scanf("%d",&num); | |
printf("DECIMAL\tOCTAL\n"); | |
for(i=0;i<=num;i++) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
day= | |
16 | |
Type the following codes for the required month | |
March-1 April-2 May-3 June-4 | |
July-5 AUgust-6 September-7 October-8 | |
November-9 December-10 January-11 Febraury-12 | |
6 | |
Last 2 digits of year= | |
19 | |
first 2 digits of year= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<stdio.h> | |
#include<conio.h> | |
void main() | |
{ | |
int year; | |
printf("Enter the year\n"); | |
scanf("%d",&year); | |
if(year%4==0) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<stdio.h> | |
#include<conio.h> | |
void main() | |
{ | |
int num,result; | |
printf("Enter the number\n"); | |
scanf("%d",&num); | |
result=num%2; | |
if (result==0) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<stdio.h> | |
#include<conio.h> | |
void main() | |
{ | |
int cp,sp,tl,tp; | |
printf("Enter the Cost price\n"); | |
scanf("%d",&cp); | |
printf("Enter the Selling price\n"); | |
scanf("%d",&sp); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<stdio.h> | |
#include<conio.h> | |
#include<time.h> | |
#include<stdlib.h> | |
void main() | |
{ | |
char player1[10]; | |
int in1,in2; | |
printf("HELLO, WELCOME TO ROCK, PAPER, SCISSORS GAME\nWhat is player1's name?\n "); | |
scanf("%s",&player1); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<stdio.h> | |
#include<conio.h> | |
void main() | |
{ | |
char player1[10],player2[10]; | |
int in1,in2; | |
printf("HELLO, WELCOME TO ROCK, PAPER, SCISSORS GAME\nWhat is player1's name?\n "); | |
scanf("%s",&player1); | |
printf("What is player2's name?\n "); | |
scanf("%s",&player2); |