Beginners - May 2019 (Page 9)

by rkwan
Chutes and Ladders
This is my unfinished code for Chutes an Ladders. How would I get draw_board and draw_box to print in rows and columns? Any help is appreciated. Thanks #i...
May 15, 2019 at 7:25pm
[no replies]
cin.fail() is still executing when there's an integer in the front of the input.
Why does the code below still execute and move on to the next line when it's not supposed to. Here's an example, when amount_input is 2w , the program still ...
May 15, 2019 at 11:27am
[4 replies] Last: Hello mrtammy2008, When I look over the responses I feel as you do no... (by Handy Andy)
How to handle stoi conversion error?
I am trying to convert a string to an integer using stoi, I have never touched on try catch and don't know how to handle the exception or error given by stoi. T...
May 15, 2019 at 9:47am
[8 replies] Last: No, due to line 13. Yes, due to line 9. Why are you wasting your ti... (by Duthomhas)
Simple code isn't compiling
Hey y'all, this simple code I've been working on isn't running on visual studio. I'm not sure why, although it stopped working after I attempted the for loop. T...
May 15, 2019 at 5:09am
[4 replies] Last: @mbahmimpi Hahaha (by MysteryFlavour)
by JayGln
printing linked list
I have a linked list that I am trying to print out part of a movie theatre POS system for sold tickets. I made a class(Sale) that holds all my data for the numb...
May 15, 2019 at 4:14am
[12 replies] Last: Hello Andy, Sorry I haven't responded I was trying to find a way to m... (by JayGln)
by hixtus
Incorrect/Partial Output - Stuck please Help!
Hello! Please help. I'm stuck. Thank you so much :) I was tasked to create a program that would output the shortest paths to all other nodes . So for example...
May 15, 2019 at 3:40am
[1 reply] : Duplicate. http://www.cplusplus.com/forum/general/253681/ (by Duthomhas)
Does a set in C++ run in parallel, if not does C++ contain a set that takes advantage of OpenMP?
The standard container in C++ called a "set," I don't think it uses multi-threaded programming because it only uses one binary tree correct? Is there a conta...
May 14, 2019 at 10:15pm
[7 replies] Last: [quote=sadraint]I don't agree with you With whom? About what? (by Duthomhas)
by Sholi
incorrect output of stof() function
I wrote a program to read lines from file, which has few float numbers written on it, length of decimals is 6 to 7 , but when converted to float using stof() l...
May 14, 2019 at 9:50pm
[4 replies] Last: Why? I can understand your point for more complicated code but for ba... (by jlb)
Under http://www.cpp.sh long same size as long long
// Test long vs long long #include <iostream> int main() { unsigned long long x(~0), y(0), z(x); for (; z > 0; ++y, z /= 2); std::cout << x...
May 14, 2019 at 9:31pm
[8 replies] Last: On gcc you can include <cstdint> and try __int128_t or __uint128_t. ... (by MikeStgt)
VS Warning if Initialiser List Added
If I define the constructor without an initialiser list, there is no warning, but as soon as I add an initialiser list, I get the warning 'function definition n...
May 14, 2019 at 5:47pm
[7 replies] Last: No problem. [quote=Varrick]You can get the fancy quote header with th... (by calioranged)
by Pecvx
Simple logic question
What does the logical expression !vec.size() == 0 mean? I tried googling it, but didn't really find any answer.
May 14, 2019 at 2:01pm
[4 replies] Last: I agree, simplify and clarify. first, the original expression does 2 ... (by jonnin)
Fitting
Hi every one. I have two text file. I wanna to fit two curve on this data points and then i wanna to find the cross point of two curves. can you help me?
May 14, 2019 at 11:44am
[5 replies] Last: This two text file are the result of my main code Sorry, but if you ... (by MikeStgt)
While Loop
I set up a while loop as a validation routine that lets the user type quit to quit. For some reason the loop enters as true when I have tried to make it false. ...
May 14, 2019 at 10:39am
[4 replies] Last: strcmp() is found by #include <cstring> > Actually it seems to be w... (by salem c)
by sk123
What is the approach to this problem? (1,2)
https://www.codechef.com/MAY19B/problems/MATCHS Ari and Rich are playing a pretty confusing game. Here are the rules of the game: The game is played with ...
May 14, 2019 at 10:09am
[25 replies] Last: > Question 4 of May Long Challenge ADA ROOKS 2, what is the approach ... (by anup30)
Doubly Linked Lists - Pushing to front of List and Printing Backwards
Please Note: This is a homework assignment, however, it was due ~3 weeks ago and I'm only doing it for the learning aspect. I'm trying to make the program pu...
May 13, 2019 at 9:27pm
[13 replies] Last: Thanks for your replies keskiverto and MikeyBoy! Very informative. Apo... (by PiggiesGoSqueal)
by AxA
Do you know a good C++ interactive course?
Hey, i am looking for an interactive c++ course online. Not only videos! i want a course where i can practice my skills too. do you know any course like th...
May 13, 2019 at 4:32pm
[1 reply] : I'm sure there are lots around if you look, but here are a few places ... (by Cheddar99)
by medosz
Calculate and store value in data member
I wrote a program. It should calculate the VAT and the net cost of the bills. Anyone can tell me how can I calculate the net and the VAT and to store its valu...
May 13, 2019 at 12:00pm
[1 reply] : You have two options: * call bill1.setVAT() and bill1.setNET() before ... (by keskiverto)
by dd95
LNK2019 even if I included the lib (1,2)
Hi, I create 2 solutions, one is supposed to be a library that I now need to use in the second solution. I followed all the steps I found online, so write t...
May 13, 2019 at 10:45am
[20 replies] Last: Hi, I managed to find the problem, but not the solution. So there is... (by dd95)
Variable in other class is not updating.
Hello, I have an app where user can change a variables - delays, hotkeys etc. I do the "config saver" but it recieve "old" (not updated) variables. "Variable ch...
May 13, 2019 at 10:12am
[10 replies] Last: Oh thanks, working! (by jacapiwsko)
toupper
I have created a function that takes an array of chars, and two arguments as bounds for indices that are to be checked if a word is a palindrome (spelled the sa...
May 13, 2019 at 9:15am
[4 replies] Last: I can see it with the pointers in the if statement. That makes it work... (by stoneJax)
May 2019 Pages: 1... 7891011... 16
  Archived months: [apr2019] [jun2019]

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