General C++ Programming - December 2017 (Page 8)

Need to slove c++ error as soon as possible
 
Hello , I need to create a program to simulate waiting time, and I am following à tutorial on dat...
[2 replies] Last: Thank you a lot now I understand well, and it is okey now Thanks (by Mar1990)
Problem function calling, with compilation options
 
hi! I'm developer of a program designed to provide features for games under GoldSrc (Half-Life #1 b...
[6 replies] Last: Sorry I didn't reply yesterday. I was totally wiped from training and ... (by helios)
Help Needed in completing STL-like list class
 
I have this code here in the following Gist that implements an STL-like list class: https://gist.git...
[6 replies] Last: Why would it cause confusion? I thought that providing a default argu... (by DragonOsman)
Why does the string become a loop?
 
I am trying to make it so it replaces every r in a word with 3 r's. Ex: there }
[4 replies] Last: @restinpasta, Please don't delete your post: people took trouble to a... (by lastchance)
by Dani95
How to find odd and even numbers in string array using func
 
How to find odd and even numbers in string array and put the odd number in array and even numbers in...
[1 reply] : 2 ways... you can convert the strings to integers and use %2 or you ca... (by jonnin)
HELP WITH PROJECT c++ (Array, string file, sort)
 
Okay, I have this project due today. I have written the codes. I need to read a .txt file and put i...
[1 reply] : On line 78: why are you comparing an integer with a string? minValue i... (by goldenchicken)
by ed13
Infinite for loop
 
I'm having some odd results in the following code: while (shapes.size()>1){ for (...
[5 replies] Last: I've found that a simple (int) cast does the trick and stops size from... (by ed13)
by haley8
CGPA
 
#include<iostream> using namespace std; void Introduction(string, long); float CalcGPA(float, floa...
[1 reply] : I couldnt run it. What do you mean? Does it fail to compile? If so... (by MikeyBoy)
How to Prevent TLE from happening even after unnesting loops
 
My code ended up with TLE even after i unnested loops. I had switched algorithms between versions bu...
[4 replies] Last: Ok here's version 3: https://pastebin.com/xEFesV00 (by includebits)
Encoding
 
Hey, I wrote this code and trying to decode the codes that I have in my packets.dat file. In the pac...
[no replies]
!! Due in 4 hours !! Recursive function
 
Hi! I have an assignment it's called the Markov-Chain. In principe I have a Directed Graph with 10 ...
[2 replies] Last: There are 2 "Fische". You can see this at the init_graph function at t... (by lekfanda)
Why is this code "disgusting"?
 
In the book PPP2, there's a "Try this" exercise that says: Why are we so disgusted with that use of...
[3 replies] Last: v is not very descriptive. If I saw code like that I'd just delete it... (by SamuelAdams)
Why is my minimax algorithm not working?
 
Hi, I am a new user here and I would like somebody to help me with my minimax algorithm. I have been...
[6 replies] Last: Yes Peter, you are right, I wasn't returning a score at the end of the... (by Chris LF)
Singleton Instantiation Syntax
 
I am using VS2017 on Win Pro x64. I am having trouble with the proper syntax for instantiating a ...
[6 replies] Last: This is not true. Thank-you for correcting me. Actually, I meant ... (by doug4)
i need some explanation about the exceptions.
 
Hello everyone. i've got a several questions in my mind,but first take a look at this code: cla...
[1 reply] : 1-)why does the what() method returns (const char*)? So you can use ... (by Repeater)
How to pass size of an array from command line
 
Is there any way to pass the size of an array using a command prompt. #include <iostream> using ...
[4 replies] Last: Your code at line 8 int arr ; is not possible in standard C++, beca... (by Chervil)
double Writing to and reading from binary file
 
Hello People! I am trying to write and read double to and from binary files. I am using the follow...
[2 replies] Last: Thanks Chervil, you are right, the problem seemed to be in a MPI I/O ... (by dariodem)
by Sh0es
Using Paths with Spaces in Build Scripts
 
I'm switching between VS Code and CodeLite for programming in C++, and one of the reasons I haven't ...
[1 reply] : all hail the mighty underscore > Both programs require me to specify ... (by ne555)
How to find matched character in string using input file?
 
Hello everyone: I am trying to write the code that can searches the string for the first character ...
[12 replies] Last: @benhart Thanks for your comment. Sure, i will definitely do my own co... (by HAKAN FRED)
Array vs Vector
 
I'm really confused on how to manipulate my code and change it from array into vector. This is th...
[3 replies] Last: First, please use code tags when posting code. See http://www.cplusplu... (by keskiverto)
December 2017 Pages: 1... 678910... 13
  Archived months: [nov2017] [jan2018]

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