Beginners - December 2018 (Page 8)

by Dum
need help in optimization.
 
Chef is serving dishes at a feast full of colorblind people. He is adding dishes one by one to a long table to form a sequence of dishes; for each dish he adds,...
[8 replies] Last: If this is for a Codechef competition, you should know that the adjudi... (by MikeyBoy)
How to test crossplatform C++ code?
 
Hello, everyone! I've implemented a simple library in C++ and uploaded it on github. Now I want to be sure, that it works on Windows/Linux/OS X. I have some ba...
[no replies]
Help with list homework please
 
exampple:7, 3, 5, 4 -List the total count of odd values in the linked list(from example above: 3) -List the nodes data value of odd integers (from example abo...
[8 replies] Last: @lastchance, Sorry about that I must have accidentally deleted the cl... (by Handy Andy)
( clearing ) a modified container
 
Hello all, I need to shrink this container like a stack ( FIFO ). So I thought about queues or stacks which have a member function pop(). Wonderfull, because...
[3 replies] Last: > like a stack ( FIFO ). stack is LIFO queue is FIFO > Hope you can h... (by ne555)
Is This Linked List Function On Point?
 
Hello. So I created this code for my last project for my CS class, yet I know there are problems with it but I need help analyzing this code. Would this work fo...
[1 reply] : > if (first == NULL) //Case 1; list is empty. Maybe you should retu... (by salem c)
Wrong card total
 
@rocketboy WHY DO YOU USE DOUBLE AND TRIPLE LINE SPACING? IT MAKES IT HARD TO READ Have a look at your routine void deal() Especially lines 434, ...
[8 replies] Last: Yeah even I wonder why that moderator deleted his post. I very much ... (by MikeyBoy)
I dont know what I'm doing wrong
 
Hello all, so i have done this program to be used by the (police) to add tickets (this is not real for the police) but every time i run it it just keeps repeati...
[3 replies] Last: addNewTicket() doesn't actually add any new tickets. It just writes th... (by Peter87)
complex numbers
 
how to write coding with complex numbers, just an example to make me understand more. and how to design in it 'myform' in visual studio. thank you.
[1 reply] : Not sure what you want to do. About complex numbers: http://www.cplusp... (by Thomas1965)
Converting hours to seconds, seconds to hours
 
Hello, Ive got this assignment where we need to calculate the inputted seconds into hours, minutes and seconds and vice versa. Ive been at this for a while no...
[10 replies] Last: Oh right, think i get the references now. I didnt realise i can simply... (by wirelesskill)
Two Dimensional Arrays
 
I am stuck on completing one of my functions, which consists of a two dimensional array that has to calculate the average for each column. I have tried switchin...
[14 replies] Last: That makes sense for a program that is in real life. This program is a... (by stoneJax)
forward trigo
 
how to write forward trigo coding? in process doing my asg. and how to design in it 'myform' in visual studio. really need help, thank you.
[no replies]
quiz score not displaying properly
 
I am working on a quiz for my class project but I am having some issues displaying the grand total. I created a class to set and ask the questions as well as ta...
[5 replies] Last: Thank you it did help, I corrected the mistakes with total and guess. ... (by PermThesis)
Ostream To String Help
 
Why is cout giving an error, cannot convert ostream to string? And if that's the problem does anyone know a way to do that? #include <iostream> #include<vect...
[2 replies] Last: You are missing the includes of two required headers: #include <str... (by JLBorges)
Checking an object for a combination of identities
 
Hi Say I have an object E, which has multiple members - a bool B, an int I and a char C. Now say I want E to have a member function (F) which takes in a c...
[5 replies] Last: #include <optional> struct A { bool b; char c; int i; constexp... (by mbozzi)
Help with fairly easy C++ HWK problems
 
Hi! I need some help on these three problems. a) Wirite a for-loop to create the sum of the integers from 0 up to and including a given integer in the vari...
[1 reply] : For question 1 and 2, http://www.cplusplus.com/doc/tutorial/control/ F... (by chicofeo)
Error printing Arrays on Traffic Jam Game
 
This is a project we're working on for our final project where we have a game field thats populated with X's and O's that start and standard positions, for exam...
[3 replies] Last: See how you delete HB on line 78, and then on line 79 you set it to ... (by Repeater)
by Grime
Need help coming up with approach (1,2)
 
So I want to make a hangman game, where the computer tries to guess the word you're thinking of. How would I find the most repeated letter that only 50% or ...
[31 replies] Last: Eventually I want to add UI for the program itself to allow the user t... (by Grime)
by rad
How to make multiple classes
 
Can someone help.I have been struggling with this for hours can't figure it out how to make it work.Here is my code: #include <iostream> using namespace s...
[3 replies] Last: Thanks guys you were helpful. (by rad)
Hash Table Serialisation.
 
How can I serialise a hash table?
[4 replies] Last: just dump the whole thing as a binary blob This will only work if th... (by dhayden)
Should this function be a member of parent or child?
 
Hi I have a class C, which has a vector of objects of class E. Objects of class E will often 'link' with other objects of class E - if two objects of class E...
[2 replies] Last: I see no reason to involve C: void E::link(E &other) { E.linkedID... (by dhayden)
December 2018 Pages: 1... 678910... 22
  Archived months: [nov2018] [jan2019]

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