Beginners - October 2015 (Page 15)

Help with code
 
I have this code and it works perfectly except Hex=0 doesn't work, i tried to add IF statement but it added 0 to all the 255 the outputs of Hex, can someone tel...
[3 replies] Last: Bummer. I see what you mean. One problem that stood out even on looki... (by closed account 48T7M4Gy)
by louwin
How do I use my PC to program pretty patterns on my TV/monitor?
 
I have been playing with C++ for about a year on a few Arduino MCs. No formal training but a retired BASIC programmer. A couple of months ago I got a 320X240 TF...
[6 replies] Last: You might find Processing ( https://processing.org/ )to be a good fit ... (by cire)
Can I write to a file without ofstream?
 
I'm trying to write a quick function that asks the user for their name, and how many sales they made during a sales period. I know you can write in a file with ...
[1 reply] : std::cin is an input stream, so no. You can write to a file using st... (by helios)
Passing Parallel Arrays through a function
 
Hi everyone. I was wondering if it was possible to pass parallel arrays through a function. I've looked around in a couple of my go to sources, but I can't seem...
[10 replies] Last: Figured that out shortly after I posted that. Perhaps next time let ... (by closed account 48T7M4Gy)
by kmn90
Help with hangman
 
Hello everyone. I need help getting a hangman program to work. The basis is that it is supposed to read from a file, select a word from the file at random, the...
[1 reply] : The programs code itself is here: #include <iostream> #include <stdlib... (by kmn90)
by sleeky
Continue entering in array where previously left off
 
Hi. i am working on a code in where the add_values selection will allow the user to enter numbers into an array. My question is : how can i change my code so...
[3 replies] Last: Well it depends exactly where you want to stop and start but the idea ... (by closed account 48T7M4Gy)
Passing Command Line Arguments
 
I need to pass values from the command line and add those values together and output the value, unfortunately it's just giving the answer 0.0000. Inside my c...
[3 replies] Last: Thank You :) I figured it out with your help. (by codingn00b)
Help with code while loop
 
I recently started a tutorial and the following is my take on the first challenge episode. For some reason one of two things is happening. Either it doesn't det...
[1 reply] : Perhaps a clue as to which line detection occurs would help us help yo... (by closed account 48T7M4Gy)
Help with nested loop
 
I need to make a user defined size ( assume odd number) rectangle with a cross in the middle to be outputted. RIght now it just spams the screen with . . . . ...
[5 replies] Last: Thank You ! for (int r = 0; r < numRows; r++) { for (int c = 0;... (by codingn00b)
Need help with this hw question
 
Calculate the exact change (coins) that needs to be given. Program prompts user to input an integer which represents the total cents (change) that needs to be ...
[1 reply] : You could use that as a start, especially modify it as a piece of pseu... (by closed account 48T7M4Gy)
Else before if error
 
Hello, I just started learning C++ two days ago and I have done some stuff. Am trying to make a basic calculator but I keep getting the error 'else' without a p...
[5 replies] Last: Line 26 should also start 'else' and not 'else if' Only one set of br... (by closed account 48T7M4Gy)
array issues
 
Hi, I'm not sure how to title this, so I'll just explain my issue. My program is supposed to print out the lowest, highest, and average registration costs for...
[2 replies] Last: We haven't covered vectors yet, so I don't think were supposed to use ... (by jpanther)
by yehozz
Call for the method?
 
Helo, so i made this code, i want my method to write out this information when i call for it. #include <string> #include <iostream> using namespace std; ...
[5 replies] Last: Use the main function from the first code block with the placement of ... (by tallyman)
Reference Parameters
 
Hello! Can someone please tell me what reference parameters are? For example, what's the difference between "void subprogram(int n)" and "void subprogram(int...
[2 replies] Last: when you do pass by value the compiler makes a copy of the passed vari... (by closed account E3h7X9L8)
how to start a number with a specific number
 
there is a something specific how to start a number with a specific number like a and after whatever number ? like the job of * cin>>id; if (id = "1*") ...
[2 replies] Last: If you are actually dealing with numbers (and not strings), there is a... (by Duthomhas)
3 Functions?
 
Write the following 3 functions. a) A function the prints three asterisks with three spaces in between each, starting in the first column: * * * Do not print a...
[1 reply] : The problem here is that you could be making any one of a dozen mistak... (by Computergeek01)
reading from a file and storing data into a struct
 
I am trying to read data from a file and print it out the screen. I am trying to store the data that is read in to a struct. I feel like I am using either the w...
[6 replies] Last: Sorry for that. It just a thorn in my side: no one ever in my memory u... (by MiiNiPaa)
How to use an if statement to check if string exists in a specific array?
 
Hello, I need to know how to use an if statement to check if 2 string elements are in an array that contains 7 string elements for names. Also after that if the...
[1 reply] : If it has to be a simplistic array like this then you would iterate th... (by Computergeek01)
Spliiting a string at a delimiter and saving to a variable
 
The code below splits a string at the delimiter and then prints each string out, so it ends up looking like the following: scott tiger mushroom I would li...
[2 replies] Last: Using the standard regular expression library: #include <iostream> #... (by JLBorges)
by qia360
HELP: Segmentation Fault
 
I tried to run this program, somehow, it runs then after entering an input number.. it stops and says: Segmentation Fault. I am using a Mac 10.5.8, and used th...
[2 replies] Last: thanks.. (by qia360)
October 2015 Pages: 1... 1314151617... 57
  Archived months: [sep2015] [nov2015]

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