initializing values for arrays, and chaging them w/o using scanf

hey guys!! just discovered this site! It's great! went over the threads..very helpful to guys like us..
anyway, i got this program that needs to simulate a simple airline seat reservation. I can initialize values for my text arrays but cant modify or change them without using scanf(). Thanks!!

Well, youre trying to print a char or a string? if you're trying to print a whole string (array of char terminated by null) you should remove all the [0] from the names, just stay, a,b,c,d. and if you're trying to print a single char, change all the %s to %c

scanf("%s",y);

Wrong 'y' is a char, and not an array of char, change to %c, and don't forget the & operator.

>>shouldn't do with 2D array of strings, // with a simple array of char
Why? How about if they wanted to have something meaningful in the array, like "reserved", "free", "taken", "window seat". Anyway, that's a lesson for tomorrow for the OP.. so we'll leave it there.

hey guys! im back! seems we have a bit of confusion. well actually its my fault cause i did not state clearly the problem. well the program im making is for my finals case study in our university. our professor said that in making the program we should use functions and arrays, either 2d or single. the problem is im quite confused when it comes to arrays..i was taught by him that in declaring a char array there must be two elements..for example :

Code:

char text[5][30];

The first one is the number of elements then the next one is the maximum number of characters. is that right? About the rules, our prof said we should stick to the rules. very strict when it comes to that. and i should be ready to defend that if ever..so i hope you guys wouldnt give me those advanced syntax cause im just a newbie in C programming...

wheeee!! i guess i did it this time!!
i got it now! the program actually works now! thanks for the help guys, below is the code..you are all welcome to comment on how to improve it well. anyway it still lacks the screen design it needs...so im off to improve is looks..

it gets messed up when i add the needed screen design..oh its not because of the "\n" you forgot to place. i tried the loop before but its no use because i use the gotoxy() and gets really messy when i add the ASCII codes to make borders and stuff..