Beginners - April 2016 (Page 18)

by Zorac
Find a partly match instead of perfect match (if-statement).
 
So i have a function that checks my vector for a search result (name_part) and if want my if-statement to return true if i found a partly match instead of exact...
[1 reply] : So how much of a match do you want? Would just "O" satisfy your sear... (by AbstractionAnon)
Nested switch problem
 
For my uni coursework I need to make 10 different functions and put them into one .cpp file in a switch so that one the program is run you enter the question nu...
[2 replies] Last: Thank you, that seems to have solved the problem. (by PWookie)
If/Else Help
 
I am creating a geography test with a menu system. I'm using if/else statements to either ask the user to re-submit their answer or move on to the next question...
[1 reply] : Worked fine for me as long as I entered the correct answers (subject t... (by AbstractionAnon)
by hayyan
best ui for gaming purpose
 
Which UI is best for developing games for any platform like desktop android etc in c++ language?
[5 replies] Last: If you really want to code android games I think you should start with... (by jgg2002)
calling a function inside another function
 
Hey guys im facing an issue where im trying to make a chart that is only prime numbers and im having an issue where its displaying all the numbers. #inc...
[12 replies] Last: Well, I already described what you need to do. Define an integer varia... (by Chervil)
Why isn't my vector code working?
 
I have this one line of code that gets and error and I don't know why. I'm making a menu that pulls up a .txt file of student information and then displays it ...
[1 reply] : I'm guessing that you are talking about an error like this 41:8: erro... (by coder777)
HELP!!
 
Thank you so much! I don't know why the code doesn't work.. #include <iostream> #include <iomanip> using namespace std; \axes, CPP, EI, UD; void Displ...
[5 replies] Last: I am afraid it's not ok. error C2660: 'DisplayPay' : function does no... (by Thomas1965)
Line spacing dealing with files
 
Everytime I run it, It shows up like this... 4/16/16 10:55pm Withdraw 35$ 4/16/16 10:58pm deposit 50$ This is what shows up from my transHistory function,...
[17 replies] Last: > What does this error mean? An old (pre-C++11) compiler/library is b... (by JLBorges)
Help with arrays and pointers. (Skipping an element/index while copying)
 
When copying one array to another how could I go about skipping an index/its element? I'm incredibly lost.
[1 reply] : Perhaps you can use the continue keyword. (by Arslan7041)
What is the vector representation of an integer or variable?
 
How would I represent ++N in its vector form?
[2 replies] Last: maybe something like: vec.push_back() ? (by Mboxer511)
Arrays, Functions, Prime Numbers
 
I need help with this program. Nothing I've done seems to be working. What am i doing wrong? Convert the program we did in class to use functions wherever possi...
[1 reply] : The error C2660 is because you only passed in two arguments to input(... (by Tyler T)
Roulette game
 
Hi, im new to this forum and been trying learn C++ on my own now as a fun project i wanted to create a Roulette game but now i came across my first pr...
[4 replies] Last: Wow thanks for the datailed reply Sadly I don't understand much of it... (by Decept1ve)
Display which array element holds smallest value
 
The code takes 12 user entered music track times, mins and seconds separated by a space. Turns it into total amount of seconds. I then need it to display which ...
[2 replies] Last: Thank you! I just realized someone replied. I finally figured it out a... (by travina8)
Please help (Pointers, Arrays, Dynamic Memory Allocation)
 
I'm finishing this program that adds to and removes from and array using pointers but and I have figured how to code all of the required functions except the fu...
[3 replies] Last: int *tmp = new int[size - 1]; for (int i = 0; i < size; ++i) { ... (by ne555)
by BenW
Getting some negative values for volume and density. . .
 
Hi all, I'm trying to write a program that reads the data below from an input file, planetsinput.txt, computes the density for each planet and prints the ans...
[3 replies] Last: Exceeded the value of int, indeed. Thanks so much guys. (by BenW)
by ry0823
unsortedtype overloaded assignment operator
 
Hello! I'm currently using my debugger to work out a program in which a word is checked in a dictionary full of words, and then states whether it is a word or n...
[1 reply] : if (info != NULL) // It's our responsibility to set info appropriatel... (by ne555)
Error/Program aborts
 
For my program the user needs to enter the string all_data in the format author|year|author ex) Catcher in the Rye|1951|J. D. Salinger but whenever I try to ent...
[no replies]
backyard bowling problem
 
Hello everyone! this is my first semester in a c++ class and our teacher is having us write our own code. so for mine i decided to write a program to keep score...
[4 replies] Last: Is your program supposed to support more than one player, or is only i... (by AbstractionAnon)
string array morse code translation
 
I cant figure out why this is not outputting the translated morse code. i am supposed to enter string text, then convert it to morse code, spaces and all by usi...
[1 reply] : Um, where is the rest of your program? (by koothkeeper)
How do I efficiently iterate through a vector and run a method on each object?
 
My code is setup like this at the moment, I have a vector containing 5 objects of class S and I need to iterate through the vector and run the subPrint() functi...
[2 replies] Last: A loop! I never thought about that! (by Pjonathan)
April 2016 Pages: 1... 1617181920... 43
  Archived months: [mar2016] [may2016]

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