Beginners - June 2018 (Page 18)

While loop with counter
I need to make a while loop to count to 100 with only 10 numbers on each line and setw(5) to separate them. I am struggling to get this done correctly. I can do...
Jun 3, 2018 at 7:55am
[4 replies] Last: You are welcome. And if you happen to read this reply, here is a way t... (by Misenna)
File I/0 function help
Hello, I am trying to take this step by step I code my True/False function complete but I am getting an error and need help figuring it out. I still need to do ...
Jun 3, 2018 at 4:16am
[4 replies] Last: After line 31, do a simple check like this: if (typeOfQuestion == 1... (by Uk Marine)
Read File
No error, but it does not read file My class include string acno2, name_st, date2 and address_st; and I want to add new student: account ac; fstrea...
Jun 3, 2018 at 1:24am
[3 replies] Last: So it does open the file correctly, but fails at some point when readi... (by Ganado)
visual studio project template
Hi all, I got two noob questions regarding visual studio (2017): 1. I am looking for a way to create a default project configuration so i don't have to set i...
Jun 3, 2018 at 12:05am
[3 replies] Last: it's a really weird environment to work in but I've gotten the GUI bui... (by zaphraud)
Vectors C++ Out Of Range Exception
I was working on an assignment where I have to work with vector of strings, However when I run the program it throws and Exception of being out of range when _n...
Jun 2, 2018 at 9:28pm
[3 replies] Last: But you're pushing nothing into it. Check for yourself: cout << "Si... (by Repeater)
by skoepa
Getting an unhandled exception
Hello I have been following along with this Handmade Hero game and I am at the end of Day 4 I an unable to run the program because of an this error "Exception t...
Jun 2, 2018 at 9:00pm
[2 replies] Last: I am not sure exactly, I have been copying his code word for word just... (by skoepa)
by t009
Can't get Class Array within Another Class Working
I am working on a beginner project that requires an array of Class_A to be an object of Class_B Below is what I am trying class Customers{ std::string ...
Jun 2, 2018 at 8:38pm
[3 replies] Last: I need to use an array for this. Need? As in " I must practice low-l... (by keskiverto)
Enrollment system program
I'm making a program that simulates enrollment for students and teachers etc. In this program I should be able to add students, teachers and subjects. I'm done ...
Jun 2, 2018 at 4:18pm
[no replies]
Inventory & Item IDs
I'm practicing some C++ and was wondering what the best approach is to creating a basic Inventory System, where item's have their own ID assigned to them. I'm t...
Jun 2, 2018 at 3:00pm
[5 replies] Last: I've been messing around with this code for a few days and understand ... (by George1993)
What book to read after starting out with c++ by tony gaddis?
I asked this question in StackOverflow and they didn't answer my question and just linked me to an old question that did not have the answer I was seeking. I h...
Jun 2, 2018 at 10:54am
[4 replies] Last: I'd recommend http://www.informit.com/store/c-plus-plus-standard-libra... (by rjphares)
trouble with class constructor
hi. I have a trouble with my class constructor. my code: class User{ private : std::string displayname; std::string username; std::string password; pu...
Jun 2, 2018 at 7:59am
[6 replies] Last: My Pleasure :) (by H00G0)
by zapshe
How To Use Files In Code?
My question is, if I had a program that would, lets say, shuffle through a provided .txt file and count the number of times the word "I" showed up. How would I ...
Jun 2, 2018 at 6:44am
[2 replies] Last: Thanks John87Connor for showing me fstream! I've yet been able to real... (by zapshe)
Convert Counter-Controlled While Loop To For Loop
hello everyone, I have written a program that will print numbers 1 through 10 as well as show what they are when multiplied by 2 and by 10. I have written it us...
Jun 2, 2018 at 5:10am
[1 reply] : int main () { for(int x=-1;x<10;x++) { cout << setw(6) << x ... (by koopey)
Mac user, a few begginer questions like libraries
Background: Formal study in c and other languages 30 years ago, but due to a local downturn in the industry in the early 90s I stopped coding. Re-educated to ph...
Jun 2, 2018 at 1:06am
[2 replies] Last: Ok, thanks. Seems opinion hasnt changed in 30 years then. I'll just h... (by Graveling)
Reading a string from text file
Hi everyone! I have a problem when working with string in text file. For example, I have a text: <w:drawing><wp:inline distT="0" distB="0" distL="0" distR="0"><...
Jun 1, 2018 at 10:24pm
[12 replies] Last: This is what I would do, String operations, find "cx="" and read every... (by H00G0)
Any advice to avoid this error?
I'm getting an error: "variable or field 'biggestNumb' declared void." I have a task to tell the console 3 integers and it has to sort out the greatest one. I'm...
Jun 1, 2018 at 9:18pm
[3 replies] Last: What is the proper result, if input is 5 2 5 (by keskiverto)
Placing validation with multiple functions
Hello! I'm currently working on a class problem where I am calculating wind chill and cloud base based of user inputs. I have the program functioning to all th...
Jun 1, 2018 at 7:35pm
[5 replies] Last: Before C++11 the keyword auto had a different meaning. Here it was u... (by keskiverto)
Tic-Tac-Toe
I am having trouble coding this Tic Tac Toe assignment for my CIS course. The prompt for the assignment is below. "There is modification to the original assi...
Jun 1, 2018 at 7:14pm
[13 replies] Last: Icy1 wrote: @dhayden, You should harden the input a bit more I'm alw... (by dhayden)
A Function that has a return type of a parent class returning its child
I have a parent class and want a function that returns an object that is a type of one of its children. Is this possible to do in C++? As of right now I have a ...
Jun 1, 2018 at 6:51pm
[2 replies] Last: That helped a lot! Thank you. It did lead to one more problem though. ... (by Too Explosive)
by catee
Middle number square
Hello I'm new here and I need to do this task: Find all 5-digit integers whose middle square is equal to the sum of the digits and how many are they? Make ...
Jun 1, 2018 at 4:06pm
[10 replies] Last: #include <iostream> using namespace std; // Tut, tut - global variab... (by lastchance)
June 2018 Pages: 1... 16171819
  Archived months: [may2018] [jul2018]

This is an archived page. To post a new message, go to the current page.
Registered users can post in this forum.