Ok i think this is where i lost
I have done what you suggested many times but it requries a char array for every single string. Meaning i now need n number of arrays per string
Is there any...
Type: Posts; User: automagp68
Ok i think this is where i lost
I have done what you suggested many times but it requries a char array for every single string. Meaning i now need n number of arrays per string
Is there any...
Hi guys
Its been a while since i did some see
I just want to let the user enter in a few strings in store them in an array of pointers. Which each pointer pointing to the begining of a...
nevermind im retarded i know how
Thanks always
Hi
Im trying to read in a txt file but i need i need to know how many lines there are in it before i set my array size,
Do we have a C function that will go off an read how many lines there are...
fread did exactly as i wanted i wanted the whole file in an array thats it.
but if i use fgets when it goes to read line two it over writes line one see what i mean.
so if i use fread it does...
Nevermind, switched to fread and now does what i need
Thanks if i knew how to delete the post i would
Hi
Can someone point me in the correct direction here
I want to use fgets to read in a stream of data from a text file
I call fgets once and it reads the first line and stores it in my...
Thanks for the link i know all that
I dont get why this is so hard
All i want is an array that has X amount of elements each that can store a string
Thats it
My intent was to have a Char pointer pointing to array 100 wide each capable of handleing its own string
and its element intialized to null
The IDE is CODEBLOCKS
The compiler is both GCC sorry not G++
And if im trying to use redirection why would i want to use fgets?
Im redirecting the STD IN to come from a file
So what you...
I dont get this'
Im practiceing with some redirections. I wrote this and it works fine in my IDE using gnu
#include <stdio.h>
#include<stdlib.h>
Works now!
Thanks!!!
Just working with some enumerations here
in a switch.
I thought we could use a switch as long as it was a constant and an enumeration evalutes to a constant. I keep getting a compile error here....
I just found the mistake!
Thank you!
it works now!
well i guess i should of posted this 10 hours ago instead of pulling my hair out
Thanks man have a good day
sigh! ugh, thanks
Somedays i feel like i wil never be a good programmer. i need a martini and its not even noon
check this out. I changed it to this and now the top part works but not the...
no
you are not understanding my issue correctly.
a is a pointer to the begining of an array
of you create a pointer inside of the function and point them to each toher then a never gets...
Hi i tried your example exactly like that yesterday and it crashes.
Just for kicks i just tried it again. still crashes.
@mk27
Thanks for the idea. I know how to use subscripts very well. As...
I have been stuck on a simple problem for 10 hours, can someone please help
all im doing is the following.
I have a function that is being passed a pointer.
The pointer points to an int...
Thanks yes it does work. I apprecaite the help and suggestions
I would like to make it as nice as possible but bot truly unerstand what we are doing above so im gonna spend some time on.
For now,...
i think i got it!
it was the semi colon
the track i was on was working might not be simplest or prettiest but it does work i think atleast lol
#include <stdio.h>
#include <stdlib.h>
Thanks for the help guys
ill keep plugging away at it
see if i can make any more progress
right because it has been terminated
im using codeblocks
im very new to programming im a math major
so im just learning what i can and cant do
Thanks for the catch there. Do you think this...
i would love to do it an easier way
if u have a second could you explain a bit more what you have going on
why in the begining you have small-large=intege1?
i dont understand that
i cant figure out this if statment
It is driving me nuts
all im trying to do is take in for floats
evaluate them and print which one is bigger
im very new to C
must be char right?
and is it %c
for char?