Posts
 
Reputation
Joined
Last Seen
Ranked #3K
Strength to Increase Rep
+0
Strength to Decrease Rep
-0
72% Quality Score
Upvotes Received
7
Posts with Upvotes
7
Upvoting Members
5
Downvotes Received
3
Posts with Downvotes
3
Downvoting Members
2
3 Commented Posts
0 Endorsements
Ranked #1K
~10.3K People Reached
Favorite Forums
Favorite Tags

14 Posted Topics

Member Avatar for DoEds

Please use gets() instead of scanf() if you expect spaces in the user input. scanf() does not handle spaces the way you want it to work.

Member Avatar for DoEds
1
274
Member Avatar for habib_parisa

Declaring such a big array on stack (by declaring it inside a function) would probably cause stack overflow issues. If you know pointers you should declare a [icode]double **tree[/icode] inside main function (where you are defining [icode]double tree[DIM][DIM][/icode]) and allocate memory dynamically using malloc() or something similar. This way you …

Member Avatar for Ancient Dragon
0
142
Member Avatar for ahp@aol.in

[QUOTE=ahp@aol.in;1152033]Thank you very much. but what is meaning of that error: '++ needs l-value'[/QUOTE] Compiler messages can be funny sometimes. You really have to look at the code closely to figure out why it is saying so. I guess here the compiler is actually not able to change the value …

Member Avatar for ahp@aol.in
0
127
Member Avatar for lionaneesh

If you are confused about the following line, don't be. All of us including the compiler should be confused about it since it has syntax error and the comments don't match either [icode] big[big][2][2]...big[2][2]. = 177; /* this is big[5][5] = 177; */ [/icode] :) On more serious note let's …

Member Avatar for WaltP
0
287
Member Avatar for aslk

Just looking at it with a glance, you have your const int defined at wrong location. Is it compiling? You need to define them before you declare your array. Will take a look at the sorting.

Member Avatar for shah1248
0
153
Member Avatar for Morrac

[QUOTE=Morrac;1151530] The only problems are that 1) I am getting caught when trying to get the process ID ... [/QUOTE] Can you explain what you meant by getting caught?

Member Avatar for shah1248
0
162
Member Avatar for Don_k

you will have to initialize i in your for loop to the length of the string entered. To get the length of the string entered, use the strlen() function. [icode] for (i=strlen(array1)-1; i>=0; i--) [/icode] If you have something else defined in your simpleio.h that returns the length of the …

Member Avatar for abhimanipal
0
125
Member Avatar for lionaneesh

Here is a good brief reference to strcat() [url]http://www.cplusplus.com/reference/clibrary/cstring/strcat/[/url] and here is one for strcmp() [url]http://www.cplusplus.com/reference/clibrary/cstring/strcmp/[/url]

Member Avatar for lionaneesh
0
193
Member Avatar for riahc3

Simplify your work. First ignore the spaces to simplify your problems. First loop - say i - for each line so it runs from 0 to n-1 Inside this loop { First loop - j - goes from i to (2*i - 1) - print each j Second loop (not …

Member Avatar for shah1248
0
109
Member Avatar for homesweethome17

There is recursion in your count_a_fnc() function (it is calling itself) with no base case. Did you really want to do that? All you need to do is to read one char at a time just like your print_vowels_fnc() function and instead of checking for vowels, check for 'a', and …

Member Avatar for MyrtleTurtle
0
149
Member Avatar for iNach
Member Avatar for Xufyan

Hi Xufyan: The body of a loop starts from { and ends at }. If you look at your examples you have what we call nested loops - loop inside loop. In both of your examples there is an internal loop inside an external loop. [B]1st question:[/B] For every value …

Member Avatar for shah1248
0
295
Member Avatar for DCvonB

You first while loop is wierd. You should not be moving head at all. You should only be moving current and prev.

Member Avatar for DCvonB
0
307
Member Avatar for MWE_QUE

Your storeId field is defined to be only 3 chars in the struct, whereas your values (strings) are also 3 chars and there is no space allocated for the '\0' (end of string) character. This results in end of string character overflowing into the next field in the switch statement …

Member Avatar for MWE_QUE
0
128

The End.