Beginners - December 2019 (Page 7)

For Loop does only runs once
 
I am trying to fill out an array by reading data from a txt file. The txt file is in the format: fo...
[3 replies] Last: thank you salem you have solved this for me. I had already tried cin.... (by ppzz123922)
by medosz
loop with while statement
 
I am trying to write a simple money exchange program. The following should happen: User enters maxim...
[8 replies] Last: Something of little to no concern for someone learning to code. My p... (by MikeyBoy)
by Acania
Base 10 to base 16
 
Hello so I have this problem/homework for uni and it's due today and I am completely stuck. It say...
[4 replies] Last: #include <iostream> #include <string> using namespace std; string to... (by lastchance)
reading and putting numbers in an array
 
the code executes normally until it reaches the part where its supposed to find the big and small nu...
[3 replies] Last: 👍:) (by highwayman)
read/write problem with 2d arrays
 
when i run the readEm and WritEm for state and action they both come back very wrong, i can't fit th...
[5 replies] Last: Andy Notice my pm (by mr55)
by hbcpp
Is it possible??
 
Hello I was wondering if it possible to create custom functions like for, for_each, while etc. ...
[17 replies] Last: @dhayden Great example, just looking at that code I can feel the pain ... (by hbcpp)
function understanding
 
what is better in a program "writing and executing" while using the function is to declare the funct...
[3 replies] Last: Ganado peter87 Thanks a lot best regards. semsemdiver... (by semsemdiver)
Why doesn't the variable change as expected?
 
Ok so I'll admit i haven't been programming for a very while and I was trying to familiarize myself ...
[3 replies] Last: operator+= generally should return a reference to the object changed. (by Ganado)
How can I limit the value of a variable?
 
In the following code j is supposed to take the values {0,3,6,1,4,7,2,5,8} sequentially for n=3. But...
[2 replies] Last: @keskiverto Thanks. That seems to work. (by Rakib771)
creating multiple objects and storing them in a list (1,2)
 
Let's say in a class called 'coordinates', I store two variables x and y. Is there a way I can make ...
[22 replies] Last: @Repeater, thank you so much! That cleared everything up now. (by rts17893)
by noyou
How do I write a file write loop?
 
Hello I am trying to write a loop that lets me add an employee number with the data that the code g...
[2 replies] Last: Thank you, I will try this tonight. (by noyou)
HELP! How to make slot machine columns rotate separately
 
Hi guys, I'm building a slot machine console program, and I need to make the columns stop rotating o...
[4 replies] Last: Duplicate post: http://www.cplusplus.com/forum/beginner/266187/ (by deleted account xyzzy)
HELP! How to make slot machine columns rotate separately
 
Hi guys, I'm quite new to C++, but I'm building a slot machine console program, and I need to make t...
[1 reply] : Duplicate post: http://www.cplusplus.com/forum/beginner/266140/ (by deleted account xyzzy)
by larryl
NULL iterator?
 
I'm not a beginner, but I have this beginner question: When I'm using pointers I can initialize t...
[9 replies] Last: I'm still interested in totorials to help move from C++ 98 to C++ 17 ... (by deleted account xyzzy)
by momof4
how do I make possibilities true or false?
 
So, I know that number values are all true except 0, that's what keeps coming up when I try to find ...
[7 replies] Last: take a chance to learn something new. set would do it, add 1-9 to a s... (by jonnin)
vector in an abstract class
 
Let's say I create a vector inside an abstract class. How would I be able to use .pushback() from an...
[6 replies] Last: It's meaningless to try and push back a number to an object of type c... (by MikeyBoy)
Genetic Algorithm
 
Hello I'm writing a genetic algorithm code to create a string. I run the code and it gets pretty clo...
[1 reply] : Found the error: Before 'largest' should be evaluated, there should b... (by nuderobmonkey)
Swap Struct in C++
 
Hello, I want to swap elements of an array but I have an error. Why? Severity Code Description Pro...
[4 replies] Last: I was not saying to make the data dynamic (that would indeed cause cac... (by jonnin)
read/write/swap problem for array of strings
 
so i have a list of reserved words i have to read in from an input file sort and then write to an ou...
[1 reply] : sortEmRes(...) is wrong. It should be: void sortEmRes(int a, string re... (by coder777)
infinite loop in read of a .bas for lexical scanner
 
i'm building a lexical scanner. for some reason when it gets to the read of my .bas it starts an in...
[1 reply] : Hello TheJast I have several questions: 1_ Have you initialised your... (by H00G0)
December 2019 Pages: 1... 56789... 13
  Archived months: [nov2019] [jan2020]

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