// using structure enter address(house no, block, city, state) of 5 people
#include<stdio.h>
#include<string.h>
struct address{
int house_no;
int block;
char city[100];
char state[100];
};
void printAdd(struct address add);
int main(){
struct address adds[5];
//input
printf("Enter address for person 1 : \n");
scanf("%d",&adds[0].house_no);
scanf("%d",&adds[0].block);
scanf("%s",adds[0].city);
scanf("%s",adds[0].state);
printAdd(adds[0]);
return 0;
}
void printAdd(struct address add){
printf("Address is : %d-%d, %s, %s",add.house_no,add.block,add.city,add.state);
}
To embed this project on your website, copy the following code and paste it into your website's HTML: