Beginners - March 2017 (Page 23)

ICAO Alphabet program
 
Hello, when I try to run my code it gives me an error on line 28. I am having a difficult time figuring out what I am doing wrong. It might be super obvious but...
[6 replies] Last: Fixed output: Enter a word: program Phonetic version is: Papa Ro... (by cristina999)
by GodBox
Rock Paper Scissors
 
So for a homework assignment I'm supposed to create a simple rock-paper-scissors game. here is a list of requirements and hints from my teacher: Requirements:...
[11 replies] Last: a 2 input lookup table you only need one table Oh, my goodness, I ... (by Enoizat)
Deep copy with =operator
 
Is this how my operator overload class should look? SortListClass& SortListClass::operator=(const SortListClass& rhs) { // Similar to Copy Constructo...
[14 replies] Last: thanks for the spot, edited above (by gunnerfunner)
Convert char * to LPCWSTR ???
 
How can i convert char* appdata = getenv("APPDATA"); to LPCWSTR ?? i have tried this but seems not working char* appdata = getenv("APPDATA");...
[3 replies] Last: A different way: #include <windows.h> #include <iostream> #include <s... (by Thomas1965)
polar coordinate system
 
Define a struct called polar which represents the polar coordinates system for representing a point in the plan, it has the form (r, ), where x=rcos(theta) ...
[1 reply] : please help me solve this sure, the forum'd be happy to help those w... (by gunnerfunner)
IO files and Getter problem!
 
i have 2 class, unit and result. The unit have a function 'readData' that read from a file and write into the class variables. When i call the function from uni...
[10 replies] Last: function in my unit class unit.h Have you chosen to turn the name o... (by Enoizat)
by rantiv
2D Arrays
 
So we are suppose to use a 2D array to determine the temperature distribution for a two-dimensional plate with constant boundary conditions. Use a 20 X 20 two-d...
[17 replies] Last: My numbers are off and should look like this. 0.0000, 100.0000, 100.... (by lastchance)
Error: Expected initializer before void
 
Hey guys today, after a long time I was coding in C++ and I got an Error: Expected initializer before void Can anyone help? #include <iostream> #incl...
[2 replies] Last: You need a semicolon at the end of line 7. But should avoid global va... (by TheIdeasMan)
Number Analysis Program
 
I have to make number analysis program. Write a program that asks the user for a file name. Assume the file contains a series of numbers, each written on a sepa...
[1 reply] : Perhaps, int numbers ; should be double numbers ; ... (by closed account 48T7M4Gy)
Problem with display user inputted Month, Day, Year using classes
 
My Date (Month,Day,Year) program will not display the month as a string for the months of April through December if inputted. For example if I enter 3 for the ...
[1 reply] : In your main file you don't need the function prototypes since you are... (by OmegaZero69)
program skipping cin statements
 
This program keeps skipping over the cin>>m>>n statement. I can't figure out why. I've tried adding commands like cin.ignore() of cin.clear() before that cin ...
[3 replies] Last: Ah, sorry. You want space-separated inputs. Replace std::cin.ignore(... (by mbozzi)
mini calculator
 
Hi guys I am real new to coding and am having a lot of trouble writing a mini calculator program. I have written codes in the past but am having trouble writing...
[11 replies] Last: You're welcome! This is how I would write it: #include <iostream> ... (by llxx)
Reading from a file
 
I can't seem to open the file as when the program terminates after the user enters the file name. Write a program that reads a text file. The user will input t...
[1 reply] : string fileName; double totalAverage = 0; cout << "Enter the file n... (by gunnerfunner)
by djc15c
Problem with isalpha() and isprint()
 
Im trying to write a program that counts the characters in a string, i used the isalpha function in one of my functions and it worked fine but every time i try ...
[1 reply] : for(int i = 0; i < size; i++0 { if (isalpha(str [i - 1])) //... str... (by gunnerfunner)
by Angel1
A program that consist of asking the user to input a letter
 
Hello , just asking if anyone knows how to "Indicates whether the character was a vowel, consonant, number, or other/punctuation " in which the user inputs a l...
[5 replies] Last: I thought I get notifications from my email that I got a reply in my... (by gunnerfunner)
Trouble finishing a function/
 
Hello, I am having trouble writing my code for the problem which states: "Write the definition of a function powerTo, which receives two parameters . The fi...
[2 replies] Last: I agree with shadder, the return should not be within the for loop. I ... (by llxx)
Dynamic allocation memory c++ Read ini file
 
I am creating a game for steam, and I intend to create a .txt file or .cfg file or something of the genre. Because to change in the interface of the steam appli...
[no replies]
reading strings
 
I don't understand the logic of program below: #include <iostream> #include <fstream> #include <cstring> using namespace std; ifstream fin("file.in"...
[1 reply] : n is a char. char 3 is not 3. char 3 is .... well, take a guess :) ... (by jonnin)
Bank Account Inheritance Help
 
My homework assignment for school. Just wondering if anyone with some expertise could look over it. The question is: LAB 5 - BANK ACCOUNTS For this lab yo...
[no replies]
getting min number
 
okay so with my code shown below everything seems to be working fine exept for my minimum number, i have to find what the minimum number is depending on the inp...
[1 reply] : I'd recommend storing the scores in a std::vector. std::vector<int> ... (by integralfx)
March 2017 Pages: 1... 2122232425... 36
  Archived months: [feb2017] [apr2017]

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