Beginners - January 2019 (Page 7)

How does a string work?
 
Inspired by this reply: http://www.cplusplus.com/forum/beginner/248142/3/#msg1094076 So, literally, string is an array of a bunch of character. But what it...
[6 replies] Last: You need to know about pointers first though. So if you don't know abo... (by Grime)
by Rushda
error:else without a previous if
 
Hello...I'm just starting with c++ Got an exercise as such: Modify the program so that a message "Not found is printed if the value is not in the array: in...
[6 replies] Last: Thanks...modify the program as follows and it worked! #include <iostr... (by Rushda)
by dutch
Assigning pointers
 
Something we could run would be nice. What is Dictionary(*beg, *end) doing? And you can't compare C-style strings with <. You need to use std::strcmp(t, *k) < ...
[2 replies] Last: @jtruth914 Please DON'T delete your question after getting an answer.... (by MikeyBoy)
Can anyone help me about this Question
 
Postal Bill Calculator: Assume that you are working as the cashier in the poslaju office in Kedah. There are 3 types of charges summing up to be the total payme...
[6 replies] Last: all right thanks (by Sepideh)
new to programming
 
ok so im new to programming and decided to start with c++ because everyone sais its the hardest to learn iv been watching buckys c++ tutorials on youtube and so...
[5 replies] Last: thank you mbozzi much appreciated. i will look into some text books (by jrocket261)
by yup2
Vector to csv
 
Im trying output the content of my vector to a csv file that already as 3 elements, however using this code outputs 4 empty elements following each of the 3 alr...
[3 replies] Last: Hello yup2, I have thought about your problem for awhile and the answ... (by Handy Andy)
EXTENDED ASCII - How to 'cout' ? (1,2)
 
Hi to everyone! I'm trying to output in my console application characters of the OEM Extended Ascii which is the one in the photo: https://www.atlantiswordpro...
[27 replies] Last: > I just want to know what happens when you try to cast a high intege... (by mbozzi)
Dungeon Crawl Help
 
Hey, i am creating a dungeon crawl game(2D Array)... It works, if i input 'l' it moves left, restart the program then i input 'r', i move right... great... Now ...
[5 replies] Last: Wow, struct really simplified everything. I'll be sure to be making mo... (by Lunchbox)
Diagonal and vertical win condition checks
 
How do I create a function that creates diagonal and vertical check win conditions for connect 4? i have the horizontal one here: bool hwin(){ for(int r...
[3 replies] Last: That's how my teacher presented it Your prof is pulling your leg, or... (by dhayden)
column dropping
 
Write a function called drop(char c, int col) that will "drop" char c into column #col The board is 6 by 7. Connect 4 This is what I have so far: #inc...
[2 replies] Last: Same topic as your previous three threads. Please don't start new thre... (by Grime)
Tetris Help v2
 
I am trying to start a project that makes the game, Tetris. For this part, I already have seven unique 2-dimensional arrays that will represent Tetriminos (Tetr...
[9 replies] Last: What part didn't you understand? Did you read my post? Give us your id... (by Grime)
by yup2
Vector
 
Im getting an error of an unqualified id in the for loop. I am trying to print the content of the entire vector but am unable to do so. Thank you for your help....
[2 replies] Last: Thank you so much! I was unaware that it needed each element following... (by yup2)
Help with basic program
 
Hello, this program only runs to the point where I insert the value for "aoa". Why is it not running through my function and printing it out after? Thanks ...
[1 reply] : Please, use the code tags (the <> formatting button), to the right of ... (by chicofeo)
Connect 4 win checks!
 
So a Connect 4 board is 6 rows and 7 columns, I want horizontal, vertical, and diagonal win condition checks. So far I have horizontal wins checker. bool hwi...
[3 replies] Last: I would; however, in your post, http://www.cplusplus.com/forum/beginn... (by chicofeo)
Returning vector from function
 
Hello, I tried making my first function returning a vector, but I am having some problems with it. Is this set up correctly, with the function initialization an...
[7 replies] Last: vector<double> vec = calculateSeries(5000, 10); for (double val : vec... (by Peter87)
Array index out of bounds
 
What is array index out-of-bound? Does C++ checks for array indices within bound?
[3 replies] Last: vectors have a lot of good stuff going for them. But c++ arrays, if u... (by jonnin)
Tetris Help v2
 
I am trying to start a project that makes the game, Tetris. For this part, I already have seven unique 2-dimensional arrays that will represent Tetriminos (Tetr...
[1 reply] : It does not help multiple post of the same: http://www.cplusplus.com/f... (by chicofeo)
Tetris Help v2
 
I am trying to start a project that makes the game, Tetris. For this part, I already have seven unique 2-dimensional arrays that will represent Tetriminos (Tetr...
[1 reply] : Similar post: http://www.cplusplus.com/forum/beginner/248884/ and http... (by chicofeo)
Return types when arguments may be valid or invalid?
 
Hi I have a library which basically stores a collection of objects, each of which has a unique id. The library has certain functions which, for example, r...
[6 replies] Last: Consider std::optional<T> . (by mbozzi)
by gaia96
file line by line and column by column
 
Write your question here. Hi guys, i've a problem in reading a file line by line and column by column. I've a file txt with 65 columns and 20000 rows. I need...
[2 replies] Last: Hello gaia96, On line 4 you do not name a type for the variable. It l... (by Handy Andy)
January 2019 Pages: 1... 56789... 17
  Archived months: [dec2018] [feb2019]

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