Beginners - March 2015 (Page 34)

by Xefin
Assistance in a walkthrough of a lab
 
Lab: You are to develop a program that will determine what time zone random samplings of residents live. The 4 choices of course are Eastern (E), Central (C), ...
[4 replies] Last: We have to basically do the lab twice, once using CASE and then IF/ELS... (by Xefin)
Calculate the monthly sales statistics
 
"ABC Company needs a simple program to be written to calculate the monthly sales statistics of their sales persons." The sales persons have to achieve a mont...
[1 reply] : Please note, that this is not a homework site. We won't do your homewo... (by keskiverto)
I can't compile this for this reason:
 
error C4700: uninitialized local variable 'h' used error C4700: uninitialized local variable 'R1' used error C4700: uninitialized local variable 'R2' used ...
[3 replies] Last: Let me write one possible main() for you: #include <iostream> int mai... (by keskiverto)
Help launching google chrome
 
I'm trying to launch google chrome from a program, but it won't work. It opens up the console and absolutely nothing happens. I've tried the below. #include ...
[no replies]
by Lee125
Difference between refference and pointers?
 
can anyone explain what is difference between refference and pointers. Is there just only differ its symbol? And how to use it. I try to google it but i did not...
[5 replies] Last: Thanks to Peter87 and keskiverto. (by Lee125)
Best code to prevent negative numbers?
 
Hello, I went back to this old code that I wrote for fun. I realized that while invalid input is blocked, I never put in code that prevents entering negative nu...
[4 replies] Last: Thank you all, I got the code working. I used peter87's solution, but ... (by Mike Teavee)
Can you explain code?
 
Can you explain what exactly exp >>= 1 does in the code bellow? int ipow(int base, int exp) { int result = 1; while (exp) { if (e...
[3 replies] Last: I could not understand why they shift the bit to right. But it's clear... (by Je suis Charlie)
by DecaK
Qt Programming connection
 
Hello, I am new at C++ Qt GUI, I make GUI with Qt Designer, but how can I know name of variables(example) in GUI? I read official tutorial, but I still confused...
[4 replies] Last: how can I know name of variables in GUI? What GUI? Do you mean the ... (by keskiverto)
by camk16
PLEASE HELP!!! (1,2)
 
I'm going to be up front, the following question is in fact a homework question . Here's the deal, though, the mathematics alone in this question are over my h...
[21 replies] Last: Why doesn't this work: #include <iostream> #include <cmath> #inclu... (by camk16)
Looping a chunk of code
 
I need to loop from "please enter the molar concentration" to the end. The program should end when the user enters 0 for the concentration. What is the correct ...
[1 reply] : The trick is to do it in an "infinite" loop, and break out in the midd... (by dhayden)
How to calculate buy two get one free Blu-rays?
 
I am attempting to determine how to set up and equation to calculate a buy two get one free deal. Blu-ray discs are selling at 9.99 and after you buy two the...
[3 replies] Last: Buy-two-get-one means that every 3 CDs costs 2*9.99 = 19.98. So divid... (by dhayden)
Weird chinese characters
 
Hello, I have a Sieve of Eratosthenes c++ code that is working to show all the prime numbers until n (in an bool array length limit), it's working when I dis...
[1 reply] : Could you show the code where you write to the file? If the program is... (by LB)
some weird class/struct problem
 
Hi, im having problems understanding what i did wrong on line int x = l.my_light.light_number(); Im getting this message from compiler Error 1 error C2228: l...
[2 replies] Last: Ohh :) Thank you very much man!! (by etrusks)
Pointers
 
The output contains wierd shapes .... can somebody explain? plz ... #include <iostream> #include <cstdlib> #include <ctime> using namespace std; ...
[3 replies] Last: Online program for ease-of-use: http://coliru.stacked-crooked.com/a/e7... (by closed account 18hRX9L8)
by Gi Pa
Program that deletes the punctuation
 
Hi, I'm working on a program that deletes the punctuation, the program should get some sentence and then write all the words in colon without punctation. The ...
[no replies]
need help with my seconds converter!
 
hello, i am relatively new to c++ and programming in general and my professor is very vague and often gets side tracked during lecture so i dont really learn an...
[4 replies] Last: thank you! i appreciate the quick response (by calistaird)
Determining the winner of rock paper scissors?
 
In this program I am attempting to determine the winner of rock, paper, scissors. unfortunately when using lowercase letters the code will register it as an inv...
[2 replies] Last: Ah, Thanks! I guess I need to stop trying to do stuff that early in th... (by Comicalizard)
I hate using pointers, but what else can I use?
 
I designed a class, in which, I have a member function will need to use other same class type object's member, so I thought of using pointers. But I really hate...
[9 replies] Last: I hate pointers too: http://www.lb-stuff.com/pointers (by LB)
Input Validation (don't know what I did wrong)
 
Hello guy, I'm new here I finally got figure it out how to stop infinite loop when I input a character instead of integer. Now I can't input integer first beca...
[3 replies] Last: See if this helps at all: http://www.lb-stuff.com/user-input (by LB)
SOLVED
 
SOLVED
[1 reply] : you will need a cout endl after each calculation in the loop and add s... (by chouhaizi)
March 2015 Pages: 1... 3233343536... 51
  Archived months: [feb2015] [apr2015]

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