Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
Unknown Quality Score

No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.

0 Endorsements
Ranked #4K
~4K People Reached
Favorite Forums
Favorite Tags
c++ x 31
c x 5
Member Avatar for CStallion

I just need to know how to count the entries of an array like this one: [code] string array[] = {"entry", "entry", "entry", ... , "entry"}; [/code] Thanks!

Member Avatar for iamthwee
0
138
Member Avatar for vissor3

i'm taking a computer programming class, and i was given a chalange to create a program in "C++" that would tell you if the number you entered was a Perfect number, being that the sum of all the factors of a number minus itself would = the original number. aka. …

Member Avatar for WolfPack
0
234
Member Avatar for CStallion

I am having problems with a code that I would like to go something liek this [code] string array; int z = rand()%2; switch(z) { case 0: array = {"entry 1","entry 2",...,"entry n"}; break; case 1: array = {"entry A","entry B",...,"entry (letter)"}; break; } //then do stuff with array [/code] …

Member Avatar for SpS
0
442
Member Avatar for CStallion

disclaimer I'm a programming n00b so I may not know what I'm talking about. /disclaimer My question boils down to scopes. Let say I have code [code] { string mystring1; string mystring2; string mystring3; //code dealing with mystring1 //code dealing with mystring2 //code dealing with mystring3 } [/code] versus [code] …

Member Avatar for CStallion
0
147
Member Avatar for CStallion

[code] int r = rand()%2; switch(r) { case 0: string x[] = "Hi."; break; case 1: string x[] = "Bye."; break; } [/code] Will this code produce a conflict on the string "x"?

Member Avatar for CStallion
0
93
Member Avatar for CStallion

I know how to change the console text color using this code [code]HANDLE hConsole; hConsole = GetStdHandle(STD_OUTPUT_HANDLE); SetConsoleTextAttribute(hConsole, ###)[/code] But suppose I need to change colors frequently and on different output lines. Is there a shorter way to do it, like [code] cout[color=red] << "text"; [/code] ??? Rant: Google searching …

Member Avatar for CStallion
0
271
Member Avatar for CStallion

I need to insert a "é" and other such symbols. At first I just tried using é straight out in C++ and it returned Θ. So I looked at my character map and did the unicode version \u00E9 where I wanted the é and it still returned Θ. I guess …

Member Avatar for Ancient Dragon
0
3K
Member Avatar for CStallion

I apologize, the topic of this thread has nothing to do because this post was started about a parse/syntax error but I solved it on my own and now this is something else, hopefully simple! I have this function that goes like this [code] void er(void) { string erbase[] ={"parl", …

Member Avatar for Dave Sinkula
0
248
Member Avatar for CStallion

Hi everyone. I'm new, but I'll be here for a while I think :cheesy: . Here is my code so far. The delays are because I wanted to simulate typing =). [code]// #include <cstdio> #include <cstdlib> #include <iostream> using namespace std; int main(int nNumberofArgs, char* pszArgs[]) { int i = …

Member Avatar for CStallion
0
108