General C++ Programming - October 2018 (Page 6)

by volang
Receive "at char" as "@" instead of "%40"
 
When I submit a html form that contains this char ( @ ), the server receives "%40" instead. Can I "pre-set" something to get the correct char right away, or ...
[1 reply] : That's the way it is supposed to work. You need to url-decode the stri... (by Duthomhas)
by cmisip
Building a fast "blobbing" algorithm
 
I am trying to put together an algorithm for sorting data into containers. Basically, a video frame is subdivided into blocks. Each block will have a value of...
[15 replies] Last: explain your implementation My naive implementation is the code in... (by cmisip)
How do I make this for loop work
 
So I've been messing with this code for a while trying to insert an integer into a list with a function call. Here is the function call in the main file. This c...
[1 reply] : Maybe something like this. #include <iostream> using namespace std;... (by tpb)
vector
 
Each student now has 3 raw scores from 3 exams, and their corresponding weights for grade are 30%, 30% and 40%. Your program need to convert these raw scores i...
[1 reply] : I need to change the array into a vector Student s ; becomes std... (by Repeater)
How to build a program with SDL2
 
I have a program which works fine on my computer which uses SDL2. If I send it to someone who has installed the SDL2 developer libraries, it runs fine. But if I...
[8 replies] Last: Well you are gonna need to figure it out yourself then. (by poteto)
by Trev
window not declared in this scope
 
Hi i'm useing windows 10 ,codeblocks 1712, sfml 5.2 and after 2 and a half weeks i finally have it working sort of below is the code i'm useing ( its not mine i...
[4 replies] Last: I was really surprised when you said "SFML 5.2", but then realized you... (by Ganado)
program to ask for email and password
 
hi guys i am kinda new to programming i was thinking is there any way to make a program that asks for email and password and sends to the developer. thanks ...
[1 reply] : Sending emails requires an external library. Google for "sending email... (by Thomas1965)
KMP algorith with a vector
 
In the following program I have a three class hierarchy. Item is the base class and Product and Service inhererit from it. I want to implement the KMP algorithm...
[1 reply] : Start by writing the KMP algorithm. Test it. Then call it with your ... (by dhayden)
by volang
Read from text file. Set position x y
 
I can not find anything about it, but I want to ask anyway. Is it possible to read a character from a text file by setting x and y coordinates? Here is a...
[4 replies] Last: If you are allowed to use std::vector you can read all the lines into ... (by Thomas1965)
by volang
Creating GET/POST arrays
 
Hello guys. PHP is built with C. How do they manage to create/deliver "GET" and "POST" variable-array? E.g. I send a get request and the server receives "fna...
[9 replies] Last: Allright. Thank you all. I appreciate it (by volang)
by ssol
split words in file by using getline
 
hello, I want to get words which are split by tab('\t') for example, Hi my name is ssol is my inputfile. and I want to split ...
[2 replies] Last: "It doesn't work" means nothing. The code you posted does exactly what... (by Duthomhas)
C++ input and strings
 
Hello everyone I am working on a project for my CS class and I am stuck on part of it. I am new to C++ so it's been hard at times. I have a line of data in ...
[4 replies] Last: The purpose of assignments like this are to verify/enforce understandi... (by Duthomhas)
Std::bad_alloc on Windows 10 but not on Ubuntu
 
Machine: 32 GB RAM Intel i7-6700 @ 3.4 GHz I am streaming a text file into a vector with 52 doubles/element and 16 int/element. With same code and text file,...
[15 replies] Last: You should only consider a different data structure if you need to fr... (by lumbeezl)
What is wrong with this metaprogram?
 
Hi, I have taken a metaprogram from a book and tried to make it work without success. I was wondering if someone can help me, clarify the attempt. The code'...
[7 replies] Last: Got it!! Thanks mbozzi! (by JUAN DENT)
Need some help debugging a program in C++
 
Hey all, I have been working on this practice program for my coms class and was having some trouble figuring it out and was wondering if anyone could take a loo...
[6 replies] Last: Checking all the failbits gives the same side effect of checking eof (... (by poteto)
Ignoring a value with a while statement
 
I am working on an assignment that revolves around calculating the average boxes a seller sells. My main question is is that starting in line 22, if the valu...
[2 replies] Last: While that would be correct, my assignment does ask for "appropriate w... (by altbrian)
Can anyone teach me how to code this program
 
Generate 20 random numbers using rand() built-in function and store them in 4x5 array. Ensure that the 4x5 array is created dynamically using smart pointers. N...
[2 replies] Last: sir,problem was that how to to pass 2D array which is created my smart... (by swahajali)
How to link 2 exe projects in visual studio
 
Hi, I am making a Game Engine which consists of 2 projects: 1. The editor project 2. The game loop project In the editor project, there is a function called ...
[no replies]
Unknown errors in a class with multiple constructors and deep copying
 
Vector.h https://hastebin.com/zotejiqazu.cpp Vector.cpp https://hastebin.com/suxujumaxu.cpp main.cpp https://hastebin.com/jexezarage.cpp I do not un...
[1 reply] : please delete the duplicated post http://www.cplusplus.com/forum/gener... (by ne555)
Passing by reference issue
 
So I am attempting to make a sorting program using the QuickSort method. However I am passing a vector by reference I think it is that that is messing my result...
[3 replies] Last: I personally wouldn't use a stack. I would just code it recursively. U... (by tpb)
October 2018 Pages: 1... 45678... 10
  Archived months: [sep2018] [nov2018]

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