Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* Write a Simple Structure Program */
- #include<stdio.h>
- #include<conio.h>
- struct student
- {
- int roll;
- char name[], add[], city[];
- };
- void main()
- {
- struct student i;
- clrscr();
- printf("Ente Roll :");
- scanf("%d", &i.roll);
- printf("Enter Name :");
- scanf("%s",i.name);
- printf("Enter Address :");
- scanf("%s",i.add);
- printf("Enter City :");
- scanf("%s",i.city);
- printf("Roll : %d",i.roll);
- printf("Name : %s",i.name);
- printf("Address : %s",i.add);
- printf("City : %s",i.city);
- getch();
- }
Add Comment
Please, Sign In to add comment