![]() |
| | #1 |
| Registered User Join Date: Sep 2008
Posts: 58
| Array with input? please help..beginner @ 3 4 This means that I need to put an @ sign at slot 3 in my array, and slot 4. how do I do this using getline? im using ./exe <input as my command line argument, so my file 'input' looks like this @ 3 4 % 5 12 # 2 17 so obviously i have a 2 dimensional array.. so.. array[i][j] = @ if i = 0 and j = 3.. right? how do i put this in a loop? |
| scarlet00014 is offline | |
| | #2 |
| and the hat of vanishing Join Date: Aug 2001 Location: The edge of the known universe
Posts: 21,214
| Code: char buff[BUFSIZ];
while ( fgets( buff, sizeof buff, stdin ) != NULL ) {
}
__________________ If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut. Up to 8Mb PlusNet broadband from only £5.99 a month! |
| Salem is offline | |
![]() |
| Tags |
| array, arrays, beginner, stdin |
| Thread Tools | |
| Display Modes | |
|
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| can someone help me with these errors please code included | geekrockergal | C Programming | 7 | 02-10-2009 02:20 PM |
| beginner here need help with an array code | Ohshtdude | C++ Programming | 6 | 02-01-2009 05:42 PM |
| entering numbers to array in a row whithout length input | transgalactic2 | C Programming | 55 | 01-02-2009 04:02 AM |
| Unknown Memory Leak in Init() Function | CodeHacker | Windows Programming | 3 | 07-09-2004 09:54 AM |