Beginners - October 2016 (Page 36)

using and ,or in the condition?
 
Hello everyone I hope you all doing great I am trying to write a code but it would show that there is an error with my code. The real question is ca...
[3 replies] Last: but that does not answer the main question He did answer the main q... (by TarikNeaj)
Getting a random number between 13 and 15
 
Hey there, I need some help with a program I am making. When you type in certain text, it randomly prints from set responses. I have it using the random functio...
[2 replies] Last: #include <iostream> #include <ctime> #include <cstdlib> using names... (by closed account LA48b7Xj)
How do I Output only One Number Instead of Multiple in a Loop
 
I am writing a program that does multiple things. For the last part I need to output the sum of the squares of all the odd numbers between two numbers that the...
[3 replies] Last: My pleasure, Goodluck^^ (by TarikNeaj)
by murfz
Rounding a price to 2 decimal figures???
 
Hi all, I have been learning C++ over the course of the last few weeks. One task I have been assigned is to make a VAT calculator. I'm not interested in how ...
[1 reply] : Quickest way is probably using the precision member function or io man... (by filestream)
Why isn't key_comp() working?
 
Simple code below which is supposed to print out the maximum VALUE in a map (thus, the expected output below was "19"). I tried it with lambda expression and i...
[15 replies] Last: EDIT: ah, now I see why the correction was necessary. The iterator to ... (by Arslan7041)
How to get code to keep repeating until a value is entered correctly?
 
Hey, could someone help me out with this? while (number > min && number < max) { if (number > min && number < max) return number; else co...
[1 reply] : The usual idiom for this is a do while loop. int get_number (int m... (by AbstractionAnon)
HELP GREATLY APPRECIATED!!!
 
I wrote the code listed below last week and need to change it to Storing the information of each car in an array (use multiple arrays if needed). Example: car n...
[11 replies] Last: you are the best! Thank you! (by channing0411)
Merge Sort
 
Hey guys, I have just completed a merge sort program. But i just wondering if anyone may give me any suggestions for my code. Or perhaps correct me if my algori...
[3 replies] Last: Of course, it was my pleasure and I am sorry I can't be anymore helpfu... (by Hirokachi)
by snzor
Program exited with return code: -1073741819
 
I want to make a program that reads scientific articles and deletes everything between the parentheses. I can't figure out what is wrong wit it, here are some e...
[2 replies] Last: The double increment was the problem, it works fine now. Thx for the h... (by snzor)
Help Please
 
Create a program that displays the weekly gross pay for any number of employees. The user will input the number of hours the employee worked and the employee’...
[6 replies] Last: Thank You! (by tennisnash2)
Program storing/outputting large negative values for int variable depending on user input
 
I have been scratching my head over an issue in my loop for a homework assignment. I was asked to write a program which accepted input from user for population ...
[2 replies] Last: Thanks for the assistance! Adjusting that condition seems to have solv... (by deletedfromit)
Trouble with math outputs
 
So I've got this program that is supposed to give you the sum of the digits of a number. The problem is the output always comes out as zero. #include <io...
[2 replies] Last: My first suggestion is that you stop using the global variables. Next ... (by jlb)
Quick question for switch statement
 
Hello out there! I've modified my older version of 'The quadratic equation calculator' to a function.. But it seems like i can't use a switch statement like t...
[2 replies] Last: Oh i see. Thanks krako! It will look like this then: #include <ios... (by Elerobo)
Date and time not updating
 
Hi all, for a program of mine I have to get the current date and time. By looking around I found the 2 lines below: time_t now = std::time(0); std::str...
[5 replies] Last: Be aware that initialization of a static is only done once, not each t... (by AbstractionAnon)
Error: Not found in scope
 
I'm attempting to write a program that will allow me to buy and sell items using LIFO and FIFO depending on the user input. Buying works well enough (though the...
[9 replies] Last: sellWidgets() (in .cpp) Line 11: You initialize sell to 0 You never ... (by AbstractionAnon)
by yes123
Error in Structures
 
I am creating a program that displays the name and salary of the two employees however I do not know what is the code for the calculation of the salary in struc...
[3 replies] Last: Declare doubles... double NumberHours; double SalaryHour; double Mon... (by wildblue)
How to use array method rewrite the insert data of part , Thx lot !
 
#include "SinglyList.h" #include "Node.h" #include <string> #include <iostream> using namespace std; SinglyList::SinglyList() { head = NULL; } Si...
[4 replies] Last: Thx for reply ! #include "Node.h" #include "SinglyList.h" #include "... (by yahoolee)
Need help with homework
 
Ok so my teacher is really bad at explaining things and then he gives us homework that is completely irrelevant I looked everywhere on google and could not find...
[4 replies] Last: A simpler solution would be something like this. #include <iostream... (by rabster)
Pointers - double linked list - HELP
 
Write your question here. typedef struct TCBlock *TCBptr; //pointer that points to the struct?? typedef struct TCBlock { int TCBId; /* Task name...
[7 replies] Last: Hello, I am afraid I can not answer all your questions, but I hope I... (by Nico)
October 2016 Pages: 1... 3435363738... 51
  Archived months: [sep2016] [nov2016]

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