Beginners - July 2016 (Page 21)

by elay
how to properly intialize static const user defined types
 
how to properly intialize static const user defined types? class MyClass { public: st...
[2 replies] Last: Looks like it's not a constant expression, because of the function cal... (by TheIdeasMan)
Pointers and chars
 
hey guys, I'm working my way through c++ primer and using sources such as this to help me. I read th...
[2 replies] Last: Haha thank you dude you helped a lot:D (by Pixelninja48)
How to display ASCII characters from ! to ~
 
Write a program that displays the characters in the ASCII character table from ! to ~. Display ten ...
[5 replies] Last: What I mean is that each line ends with a space, and then a newline. ... (by dhayden)
by Lodi
Libgomp.spec missing
 
Hi, tried using openMP using a g++ compiler on the command prompt of a Windows 7 computer. This is m...
[2 replies] Last: Thank you Duoas, it worked. Lodi (by Lodi)
Easy Color Use
 
Hey guys, I wanted to ask a design question, but I'm still a massive noob so... The long and shor...
[4 replies] Last: SetConsoleTextAttribute() is a very lightweight function. Call it as o... (by Duthomhas)
Need some help with c++ functions (a lot of functions with combination)
 
hi, guys i'm in colleage trying to do some homework with cs10 and got stuck with this combination of...
[3 replies] Last: http://www.cplusplus.com/forum/general/194120/#msg933544 (by Naughty Albatross)
by FBHSIE
Logic error (letting me put >50)
 
Write your question here. It shouldn't be letting me put more than 40, but it is. I'm not sure wh...
[4 replies] Last: if (status==true) This can be written: if (status) { } The fal... (by TheIdeasMan)
Dynamic memory allocation inside an object
 
Is there any problem if I create a dynamic array on the heap when calling this specific member funct...
[14 replies] Last: The mind boggles at your interpretation. There is no mystery. There is... (by closed account 48T7M4Gy)
c++ madlibs
 
I have a project due at midnight and im stuck. My program isn't compiling properly. Please help. ...
[2 replies] Last: Hi, string Story ; this means Story ; string Story ; string Story ; ... (by shadder)
Help with finding sum and average of numbers in a file?
 
Hello! I got the first part of this (opening the file and getting the total amount of numbers in the...
[5 replies] Last: Just to let know your logic errors : double total; // Where's the... (by Naughty Albatross)
Having User Open a File and Word-Counter of Those Files
 
I'm literally losing my mental sanity. I have been attempting this problem for 3 days now, and can't...
[8 replies] Last: That is impossible. Did your program finish executing without you pres... (by Naughty Albatross)
Weirderror
 
when I compile my code i get this weird error. bash: line 12: 7202 Segmentation fault $file.o...
[1 reply] : In general terms this error often occurs when you're reading data out ... (by closed account 48T7M4Gy)
Calendar Assignment - Where Do I Start?
 
Write a program that prints a calendar for one year, given the day of the week that January 1 falls ...
[1 reply] : Where do you start? Best place is at the point where you realise this... (by closed account 48T7M4Gy)
Random number generator with rolling a dice
 
I have to general random number with rolling a dice (6 sides) for 4 players. while (maxScore<...
[7 replies] Last: You didn't initialize your number array from the start. Put it before... (by Naughty Albatross)
logic of boolean
 
I wrote a function that checks for duplicate numbers within an array. Could someone please explain ...
[1 reply] : Hi, bool is essentially true/false or 0/1, just think of it as a flag... (by shadder)
Function not returning average
 
I cannot find reason why function is not returning average correctly? #include <iostream> u...
[7 replies] Last: http://www.cplusplus.com/forum/beginner/194077/2/ Multiple posting of... (by closed account 48T7M4Gy)
insertion sort code
 
Hi people I just asked a question on finding the smallest number and index I have figured that out w...
[9 replies] Last: I figured out why I was getting that output changed 0 to i on line 34 (by adam2016)
How to compare 2 std::strings in an if statement
 
I'm trying to compare 2 std::string variables in order to determine if my program is running on a Ra...
[5 replies] Last: Actually, dhayden was on the spot with his answer, it does have to do ... (by hashbrown)
by Ch1156
Is this code efficient?
 
I wrote this program to test my knowledge of classes, and I think I finally got the hang of them. I ...
[7 replies] Last: NameGenerator.h assumes that you have already included fstream and ios... (by dhayden)
by FBHSIE
Questions about code and random function.
 
I just had some random questions about C++ coding I've been thinking about. For the variable won...
[5 replies] Last: I mean if none of slot1, slot2 and slot3 are the same then the last e... (by Peter87)
July 2016 Pages: 1... 1920212223... 30
  Archived months: [jun2016] [aug2016]

This is an archived page. To post a new message, go to the current page.