0

how can i declare this correctly:
because i always get an error like, too long declaration.

Type of food Name Address Average cost

Thai ABC Makati 250
American DEF Pasay 350
Asian GHI Manila 150
Thai JKL Muntinlupa 300
Thai MNO Paranaque 350
American PQR Manila 200
Asian STU Makati 400
Asian VWX Roxas blvd. 500
American YZA Manila 250

it should be printed out already in the program. tnx!

2
Contributors
3
Replies
4
Views
8 Years
Discussion Span
Last Post by Ahmed_I
0

Type of food-- Name--Address-- Average cost

Thai ------------ABC---- Makati---- 250
American--------DEF ----Pasay ------350
Asian------------GHI ----Manila ------150
Thai--------------JKL-----Muntinlupa--300
Thai--------------MNO---Paranaque--350
American------- PQR ---Manila -------200
Asian------------STU ----Makati ------400
Asian -----------VWX ---Roxas blvd.--500
American-------YZA-----Manila--------250

0

You can Make a Structure for these four identifiers.

struct  AnyNameYouLike{
 char* type_of_food;
 char* Name;
 char* Address;
 unsigned int Average_Cost;
};

I hope that i understood your Question :)

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.