Beginners - March 2014 (Page 75)

by Huppa
Need help fixings bugs/errors
 
As you can tell, I'm trying to convert inches to cm, or cm to inches, depending on the input from the user. I'm new to using char and wondering how I'm suppose ...
[4 replies] Last: You forgot a << in there. Yeah... Not like that's important or anyt... (by Huppa)
Never seen this before.
 
#ifndef SEQ_H #define SEQ_H #define INIT_VAL "A1" #include<vector> #include<string> using std::string; using std::vector; class SEQ { private: string id...
[1 reply] : Hi Cody, Line 16 has default value - if no argument is supplied it wi... (by TheIdeasMan)
by alsade
where should i release the dynamic memory?
 
i allocated dynamic memory in the function's... where should i "free" the memory? #include <iostream> #include <stdlib.h> using namespace std; int* m...
[1 reply] : After you done with it. In your code that means at the end of main(). ... (by MiiNiPaa)
Expression must have integral or unscoped enum type.
 
Hello everyone I am writing a small program for class that measures 3d distance. I have been trying for figure out what I'm doing wrong for the last couple hou...
[12 replies] Last: Actually after thinking about it I'm not sure why I didn't just multip... (by Mechennyy)
by Huppa
Need help with ASCII program
 
I need to input two characters, and print out the symbol with it's corresponding ASCII number saying which one is larger. What am I doing wrong? //char_comp...
[1 reply] : 1) Creating an infinite loop on lines 16-22 2) Casting char to char on... (by MiiNiPaa)
Passing an input file by reference into a function that returns a string
 
So i am supposed to pass an input file by reference into a function that returns a string type. The point is to read the name of the person in the file and retu...
[5 replies] Last: You have declared calcScore to take 7 arguments but on line 34 you onl... (by Peter87)
Help with shuffling cards (Vector)
 
I am trying to write a sub-program that takes a deck of 52 cards and will shuffle it up using this algorithm: Start with n=51 Repeatedly: Generate a random ...
[4 replies] Last: That sems to have fixed the problem, thank you MiiNiPaa! (by Edward A)
reading input from external files character by character
 
I'm trying to get this function to read characters from an external file one by one, but i cant seem to get it to work. when i do "FileIn.get(Ch);" the Ch vari...
[9 replies] Last: You are opening it correctly. However I doubt that your filename is co... (by MiiNiPaa)
matrixes
 
Data 1 P=[█(3 2 0 1@4 0 1 2@3 0 2 1@9 2 3 1)] and Q=[█(3 0 2 -1@1 2 0 -2@4 0...
[1 reply] : You forgot to show your current code and ask question(s) about it. (by keskiverto)
Problems writing to the end of a binary file
 
Hello guys, i'm having trouble with a program that involves writing a structure to the end of a binary file. I've condensed it to just the basics, but the conce...
[1 reply] : it just seems to write a new file, Sure thing, you are opening your f... (by MiiNiPaa)
Apple mach-o linker (id) error
 
whenever i compile this code, it gives me 4 errors and won't build #include <iostream> #include <fstream> using namespace std; string contestantNam...
[1 reply] : these 4 errors "findLowest()", referenced from: calcScore(s... (by cheagle5)
by Huppa
I need help with a ASCII value program
 
I want to write a program that will ask the user for two characters; symbol1, and symbol2. The program will then print out which character is the larger of the ...
[2 replies] Last: To get the actual numerical value of the character, cast it to an in... (by Huppa)
by kay19
Stack memory frame help.
 
Trying to practice drawing Stack Frame, so I need help here. I think the parameters/return is the one I need help on when it comes to the stack. Now here is a...
[3 replies] Last: Alright, thanks for the reply. Thanks for the description (by kay19)
by rodef
Help with a function in a numer-to-english program
 
Hello people. Im trying to make a "number to english" translator, and one of the functions of the program is that shown below (which is not working). Can someon...
[2 replies] Last: if ((a==0,21) || /* ... */ The comma doesn't do what you think it d... (by long double main)
Error while converting Str To Int
 
num1 is a string with digits and n1 is integer but im getting error while converting them .. im trying to do .. string to integer n1=stoi(num1)...
[1 reply] : See: http://www.cplusplus.com/forum/beginner/120836/#msg657958 (by JLBorges)
Design Patterns and UML diagrams
 
This is more of an "advice" thread than a code thread. I've been listening to Derek Banas's youtube tutorials on UML diagrams and design patterns, which I've h...
[2 replies] Last: Gracias, Cubbi. (by NullInfinity)
New to programming and learning c++
 
I have absolutely no experience in programming but im currently taking a c++ course at my university for my biotech degree. If i like it enough i might consider...
[4 replies] Last: Apologies for the late reply. For me, keeping a track of nested block... (by NullInfinity)
by alsade
removing duploicates while merging array's issue
 
im tryin to merge two sorted int array's without duplicates. the merge function worked well without the duplicate's part but since i added it the merge works bu...
[no replies]
Program ends abruptly if tried to enter a value or enters infinite loops
 
Hi everyone. I am a beginner with C++ and I created a program to check if the person can drive or not. For it to run properly I added a line where if a pe...
[16 replies] Last: Wow, 15 replies and we still haven't figured it out? :) Anyways, try ... (by long double main)
Simple File Stream
 
Hi, i am writing a program that will ask the user for their shoe size and brand they would like to purchase and store it in a file. it was working but all of a ...
[4 replies] Last: @danielc99: Ok but did you read what i believe is wrong in your code? (by jasongog)
March 2014 Pages: 1... 7374757677... 79
  Archived months: [feb2014] [apr2014]

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