General C++ Programming - March 2015 (Page 23)

Well-written parallelised code using C++11 features?
 
Hi folks. I'm about to evaluate an implementation of SYCL for ease of use and performance when writing parallel programs for heterogeneous environments, and ...
[1 reply] : Perhaps https://github.com/schlangster/cpp.react ? (by LB)
Need Help with my code please!!!!
 
Can someone help me why when I run my code it ask for population, rate and days 2 times. Im just trying to make it so you cant put in a string or decimal values...
[3 replies] Last: #include<iostream> using namespace std; //Sample of how to do what I... (by shamieh)
by Ezrar
GetWindowText not returning all values
 
Hi I'm having trouble understanding why my GetWindowText method is only returning titles of certain windows. Using CBT hook, I'm able to detect the active wind...
[2 replies] Last: @coder777 Thanks for the quick response and answer, GetWindowText c... (by Ezrar)
by hapi
please help me write code for this problem
 
The price of a motor vehicle in Malaysia is determined by few factors such its manufacturer and few types of taxes. However, in the duty free Island such as Lan...
[2 replies] Last: can i send you my code and you help me check? because i scare my frien... (by hapi)
Randomize (1,2)
 
I make a game that will ask you question. But the thing is, how can I randomize the questions everytime I open the program? Also, can I assign the questions to ...
[23 replies] Last: Thanks sir. Gonna watch his video :) And thanks sir because it's okay ... (by ryanjoshiii)
Dynamic arrays
 
"Write a program that dynamically allocates a float array of a size specified by the user" This my code so far, if anyone could check it and give some feedback...
[7 replies] Last: What would you want the program to do? Cuz if you use integers, it pri... (by TarikNeaj)
I need a little help with my code
 
Hi everybody,am designing a simple calculator as a mini-project,but am encountering a whole lot of errors when i run my code using devc++. Pls help me out. Coun...
[2 replies] Last: Also lines 33, 43, 54 etc are pretty strange, you are basically output... (by ashleybrown2)
Overruling new and delete
 
Hi, I have a short question regarding Overruling the new and delete operator. My Situation: I have two classes A and B. - A have a membervariable pointe...
[1 reply] : Show some code, a skeleton class B with the overloaded new and delete,... (by tipaye)
List with numbers biggest to smallest
 
Ok so i'm working on a task which i stumbled onto from some earlier days of this site (2008 or something like that) and it doesnt allow to reply anymore, so i w...
[3 replies] Last: ok so ive done this, but i cant get it to make a list. I dont understa... (by Kristofferkh)
by vtk
how do i get this function to search the array for a title or author and show it, anyone any ideas
 
void recordArray(BookRecord *book, fstream &dataFile) { dataFile.open("Books.txt",ios::out | ios::app); // Open File to store array int index = 1; //...
[1 reply] : You need to move the "No Matches" branch outside of the loop: do { cou... (by coder777)
Graphs - data structures
 
Hey, I have been reading about graphs and trees. I have read the different types of trees such as; AVL/ red/black and splay trees etc. However, I'm just not...
[1 reply] : The data structure is relatively simple: struct binary_tree_node { .... (by coder777)
Determine the points from a set of coordinates that will form a line
 
I want to make a program that generates between 10 - 100 random coordinates on the Cartesian plane and it should find which points will form a line. It shou...
[10 replies] Last: @ne555 It's obviously a recursive. You're not willing to wrap your min... (by coder777)
Ordered Linked List Iterator
 
Just want to make sure what the iterator exactly does in a linked list. Is it like the push function but this is for nodes? linkedListIterator<Type> operat...
[2 replies] Last: Iterator does in linked list exact same thing what it does in vector, ... (by MiiNiPaa)
I'm trying to find the class average but its displaying random numbers in a row. What's my mistake?
 
#include<iostream> #include<fstream> #include<string> using namespace std; const int rsize = 10; const int csize = 5; int row, col, r, c; double su...
[9 replies] Last: I JUST FIGURED OUT MY MISTAKE!!!!!!!!!! :D:D:D:D It was: void classa... (by welhour0)
repeating loop/function
 
For my program it keeps repeating the same function instead of going back to the main switch statement. after I choose which function I want to run and it gives...
[3 replies] Last: thank you so much! I initialized my sum variable. (by believedancer)
Boost zlib filter help?
 
Alright, so I already set up a basic set of binary io, where data can be written byte by byte, and read back byte by byte, whether it's u16, u32, whatever. How...
[2 replies] Last: For some reason, push() doesn't seem to be a member of iostreams::filt... (by Austin J)
by riyer
Find String In String Vector
 
This program is to solve a word maze and find the number of words in the maze from a dictionary file. The program runs, but stops by finding 1,2 and 3 letter wo...
[1 reply] : The files Dumpling2.txt is a word maze file and Dictionary is a `dicti... (by riyer)
Help about Compiler error 2016
 
I have code below: int i_n=0; i_n = lstFrmBlkTm1 .iNumb; // the iNumb is an integer in a structure. if (i_n > 0 ){ ... } the compiler complain the i_n...
[1 reply] : Show how lstFrmBlkTm1 is declared. Please copy and paste the exact ... (by LB)
I need help on my coding
 
I am doing Ulam sequence and I am not sure why its going infintely loop after going into void function. If i type 40, its suppose to go 40, 20, 10, 5, 16, 8, 4,...
[2 replies] Last: Thank YOU SO MUCH ! (by jae0014)
Vending Machine
 
Can someone help me to create a vending machine program? Im just studying C++ for almost 3 months. We started from cout and finish in looping. It is possible fo...
[17 replies] Last: Look at lines 26 - 35. Those lines run on every iteration of the loop... (by MikeyBoy)
March 2015 Pages: 1... 2122232425... 28
  Archived months: [feb2015] [apr2015]

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