
please wait
by Houd
Generate Code Depending on User Input (1,2)
|
Is there a way to generate code depending of user input? For example, if I have this code: switch (a) { case 1: a(); break; case 2: b(); break; c... |
Jan 23, 2017 at 8:08pm
[20 replies] Last: Awesome. It's the "running it millions if not billions of times" that ... (by dhayden)
|
by adam2016
another pointer question
|
Hi guys I'm getting the hang of pointers thanks to all the great people on this forum =) but I have one question here is my sample code #include <iostream> ... |
Jan 23, 2017 at 5:23pm
[3 replies] Last: anyway what is the difference between passing a pointer into a functi... (by MikeyBoy)
|
New to using files |
I have made a program that takes in a sentence from the user. Then the program makes a list of words that has one copy of each word from the sentence with no wo... |
Jan 23, 2017 at 3:18pm
[9 replies] Last: Ok thanks anyway (by boringblobking)
|
by adam2016
pointers question
|
Hi I am in the process of figuring out linked lists but one thing that is catching me out and I know it's probably fairly basic by how come when I try to create... |
Jan 23, 2017 at 2:10pm
[7 replies] Last: Thanks guy I understand it now,seems so complicated yet in reality it'... (by adam2016)
|
by Kourosh23
Arrays and Structs - BUG! - C++ (1,2)
|
Guys, my code has a bug, don't know where it is and how to fix it ? Any help? #include <iostream> using namespace std; struct x { int* array; int s... |
Jan 23, 2017 at 1:47pm
[20 replies] Last: Yeah, my prof last term was really strict with naming and all the corr... (by Kourosh23)
|
by Kourosh23
Arrays and Pointers - Reference Only!
|
Original Question from: Kourosh23 Answered by: Chervil @Kourosh23 Also, I don't understand why it is an error ? I am simply passing value to the pointer whic... |
Jan 23, 2017 at 1:34pm
[no replies]
|
by EdJames94
Signal Alignment Code
|
Hi, I'm fairly new to programming but for my final year uni project I'm needing to develop a DSP that automatically time aligns a DI signal and a microphone sig... |
Jan 23, 2017 at 12:15pm
[2 replies] Last: Essentially I'll be using a software called clio that will read the tw... (by EdJames94)
|
by onlincutie
Simple member function involving coins
|
I am trying to write a member function for a class I have. The class is called Coins, and acts as a coin purse that keeps track of how many quarters, nickes, di... |
Jan 23, 2017 at 11:58am
[3 replies] Last: In all seriousness Coins should be renamed Purse and without vectors t... (by closed account 48T7M4Gy)
|
Just starting to learn C++ using the tutorials |
Just starting to learn C++ and have encountered a problem. When I try to run the code in this: http://www.cplusplus.com/doc/tutorial/program_structure/ I just g... |
Jan 23, 2017 at 10:20am
[1 reply] : Sounds like the settings on your compiler or IDE are incorrect. Goog... (by EtDecius)
|
by adam2016
Linked list with pointers
|
Hello people I'm reading Alex Allains c++ book and I just got done with pointers to pointers which I had no problems with then we move onto linked lists but t... |
Jan 23, 2017 at 9:14am
[1 reply] : A pointer to a pointer is rarly used. There are usually two scenarios:... (by coder777)
|
by MisterTams
Need help with a program!
|
Hey guys, I wrote a program that finds the seat selection available for a movie theater and all that good stuff. I'm practically done but when the user inputs 0... |
Jan 23, 2017 at 6:43am
[1 reply] : I've tried several things but couldn't get it to work. It might mak... (by closed account 48T7M4Gy)
|
by boxter126
Random Number Generator Question
|
Hello, for my assignment we need to create a code that generates 1. n number of random numbers (from 0-100) and store them in an array 2. then we have to as... |
Jan 23, 2017 at 6:22am
[5 replies] Last: @gunnerfunner what's with all the C header files I used them too, si... (by closed account 48T7M4Gy)
|
Dynamic cast |
Please excuse this Long example, but I am not sure, which parts are relevant. My question is: Is the dynamic type cast in the following example correct? cla... |
Jan 23, 2017 at 2:47am
[6 replies] Last: from above: tries to convert the pointer returned by it->Next() to a ... (by gunnerfunner)
|
Writing to two dimensional vector within structure |
I want to write to a two dimensional vector that is part of a structure, it is of type boolean, and also, I am using SFML in my project and would like to know h... |
Jan 22, 2017 at 10:53pm
[5 replies] Last: So, I kept trying and still couldn't find an answer. (by Optimistic Peach)
|
by Tycose2014
Judges scores
|
This is a homework problem, but the only problem I am having trouble with is taking 5 scores, getting rid of the highest and lowest, then averaging out the ... |
Jan 22, 2017 at 7:58pm
[1 reply] : int largest = 1 , smallest = 0 ; if( a > largest ) { largest... (by ar2007)
|
Files - Skipping lines |
Hello! I'm attempting to read the first letter of every line, and I'm not overly sure as to how I'd get to that point. I've been able to read the first letter o... |
Jan 22, 2017 at 4:34pm
[3 replies] Last: Is there any chance you could explain how you got the program to read... (by cire)
|
by moop
how would this be done?
|
Hello, I am new to C++, basically I am trying to make a program that while you are holding spacebar a number decrements, once your health is equal to 0 I want t... |
Jan 22, 2017 at 4:18pm
[2 replies] Last: Hello moop, This is not as fancy as what whitenite1 did, but it is bu... (by Handy Andy)
|
by adam2016
pointers and multi dimensional arrays
|
Hi guys I'm trying to grasp the concept of how pointers work with multi dimensional arrays but I'm finding it hard, I know this code will get the value of wh... |
Jan 22, 2017 at 4:06pm
[2 replies] Last: thanks gunnerfunner =) (by adam2016)
|
by BojidarS
Area and volume of a parallelepiped
|
Hello.I need a class program which contains: destructor, constructor,member functions for area and volume of a parallelepiped. |
Jan 22, 2017 at 3:16pm
[1 reply] : Sure, and ? (by gunnerfunner)
|
First Letter of Every Line in File |
Hello! I'm trying to figure out how to create a program that prints the first letter of every line in a file, but I'm at a bit of a loss as to how to only take ... |
Jan 22, 2017 at 3:14pm
[5 replies] Last: Yeah, you're right. A more robust approach would be: #include <iostr... (by gunnerfunner)
|