Beginners - May 2015 (Page 15)

Cycle does not work right
 
The problem is that the Text "Enter mark: " is loaded 2 times in a roll without giving a chance to enter anything the first time. #include "stdafx.h" #incl...
[1 reply] : http://stackoverflow.com/questions/5131647/ (by mutexe)
by koopey
c++ basic terminology clarification
 
been using jumping into c++. i felt like i understood the words but was quite confused by the way and context word was used in some places. appreciate it if you...
[5 replies] Last: so a general variable of a class type is an object and each object wit... (by koopey)
Why does this Constructor/Class not call right.
 
Hello World! I have a question for all if you insightful fellows. I'm working on a small text based rpg, to help me cement a lot of C++ skills. I created a B...
[3 replies] Last: Dark Goomba, you are a beautiful god child and I shower your family wi... (by KillaCosby)
read file into array & sorting array issue
 
The code below is read file into array and i had attached the txt file link below. i wonder if this code is valid or not although it can run successfully. also,...
[15 replies] Last: noted. thank you so much sir. i had learnt so much from u :D (by jackiettw)
String does not want to accept 'white spaces' when I type and will only accept one word
 
Basically, my only problem with my code is that when it asks for the student name, and I type anything with spaces (ex. Angelina Jolie, Brad Pitt), the program ...
[10 replies] Last: Oh I forgot to tell adriyel about the getline, even though I used it i... (by minomic)
by Awhe
Not executing if statement? Unexpected results.
 
I was reading and learning c++ from the book "Programming principles and practice using c++, 2nd ed" and i ran into a bit of code (first block one below) and co...
[4 replies] Last: ty buddy (by Awhe)
Loading from a textfile and filling a vector
 
When i use this code to load the textfile into the vector and I am going to print it, it seems like the vector is filled with the same name and number several t...
[3 replies] Last: Both Momothegreat and specter113 are making bad suggestions. Your... (by cire)
How to switch back to main
 
Hi there, I am trying #include <iostream> #include <fstream> #include <string> #include <cmath> using namespace std; int main() { char selec...
[7 replies] Last: This might sound like a bit of a bad answer, but there is plenty of ma... (by tristan1333)
undefined refrence to WinMain@16 error?
 
Hello all, Im new to c++, going through teaching myself, and Im encountering many problems building functions. However, this problem in particular is stump...
[6 replies] Last: Holy crap! Shows how much attention my brain was giving you. Yes, ev... (by Duthomhas)
Trouble with program (1,2)
 
Write a program that prompts the usr to input an integer and then output both the individual digits of the number and the sum of the digits. For example, it sho...
[22 replies] Last: :) (by Codermik)
Using a existing text file and edi and save
 
How can I use my saved list to add new information in it and save it again? I canĀ“t find any information on how to do. // Phonebook /* Use this t...
[1 reply] : My quick suggestion is not closing the output file until the end of th... (by Momothegreat)
Replacing capital letters with small lettes and small letters with capital letters.
 
This program replaces the small letter vowels with capital letters. How do I get it to replace small letters with capital letters (for all of the letters, not o...
[2 replies] Last: ^ Include the header file <cctype>. It has library functions like tolo... (by Momothegreat)
Coding a Simple Game. Please assist
 
I'm not sure why I"m getting a "previous if before else" error on line 57. #include <iostream> #include <cstdlib> #include <ctime> using namespace s...
[2 replies] Last: ^ What he said: if (totalBucks >= 13) // delete semicolon, i... (by Momothegreat)
by SVcpp
Text files and Storing in variables
 
Hello, I'm currently writing 2 classes for a program I am writing and I want to be able to read in from a text file and then store what is read to temp varia...
[4 replies] Last: @Momothegreat Thanks for all of the help, but I actually got this sol... (by SVcpp)
Error while checking if .txt file is open or not
 
I want to check if a file is open or not. If not then open it. ifstream inputFile; if (!inputFile.is_open()) { inputFile.open("filename.txt"); } When I try...
[no replies]
Keylogger help
 
First, I will not use this for anything other than learning cpp. I need my keylogger to log at specific webserver eg. 123.123.123.123/LOG.TXT. I dunno if there ...
[5 replies] Last: As @ultifinitus said, there is a system hook for this so you can make ... (by iQChange)
by kunz
while loop validation
 
Is there a simpler way to write //Validating input to R,S,P and Q while (my_choice != 'R' && my_choice != 'P' && my_choice != 'S' && my_choice != 'Q')//is ...
[6 replies] Last: andywestken's solution is a very handy trick to remember. For efficien... (by dhayden)
Anyone need a student or programming buddy?
 
Hello everyone, I'm new to the forum. I have been learning and studying C/C++ on my own for quiet some time now, but I still have trouble with the following...
[9 replies] Last: Sounds cool. You help me and I'll help you too. We're all in this toge... (by SonDavid)
C++ vs assembly code
 
x=10; l= ++x + x++ + x At first I thought evaluation takes place from right to left. So we have x=10 then, x++= 10 (later it will be converted to 11 for next...
[6 replies] Last: It has to be undefined, it changes x's value multiple times during the... (by TheHardew)
Issues with loop
 
Ok Im trying to have the program end when the person enters "done" on either input1 or input2 and its still requiring the person to enter "done" and "done" on b...
[3 replies] Last: When the user types "done" in either input1 or input2 then the loop sh... (by specter113)
May 2015 Pages: 1... 1314151617... 40
  Archived months: [apr2015] [jun2015]

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