Beginners - April 2014 (Page 40)

Best way?
 
Alright, I got the code all set and it works perfectly. I just want to know if I did it the best way or if I'm missing some shortcuts. This is just a practice p...
[2 replies] Last: ahhh thanks ! I have it start with 1 because of where the counter is. ... (by football52)
cin.get() question
 
I am trying to get a string as input from the user and store each character in a linked list (each character getting it's own node). I am using a sentinel for w...
[1 reply] : Use getline instead getline(cin,vig); will put your input into the... (by closed account 2UD8vCM9)
by Alam
Ideas?????
 
Can anybody tell me the ideas regarding advance databases. its a semester project. Ideas can touch the areas like: 1- Temporal databases(time) 2- Spatia...
[no replies]
by dan2n1
palindrome need help
 
Hello everyone, I am very new to C++ and have no programming experience. I need help with palindrome. My professors says its not correct that, I need to use ...
[2 replies] Last: The instructor did not state which headers are missing. I will continu... (by dan2n1)
Why is this code throwing me a segmentation fault?
 
I'm working on factoring out of a nth root problem and I have started my code but am having trouble as it keeps segmentation faulting when I test it. Any help w...
[2 replies] Last: Also, line 38 should probably be varCount.push_back(count(factors.beg... (by long double main)
Question regarding string.append()
 
Hello! I need to bug the community once more. I have this bit of code, below. I'm trying to append a string (chance) to a second string (triedLetters), previo...
[4 replies] Last: Thanks for responding. Oh, sorry, I must've missed it. Close guess! ... (by Powdertrail)
keep getting 0
 
the program generates 5 dice rolls and checks for three of a kind it loops through this a set number of times however the percent keeps coming out to be 0 and i...
[1 reply] : This is a case of floating point division errors. Considering the tota... (by TwilightSpectre)
by toast9
member function not recognizing member variables
 
I keep getting errors saying kSize and answerArray are undeclared identifiers. Am I missing something to get the member function to recognize member variables? ...
[2 replies] Last: Ahhh thanks, completely forgot that! (by toast9)
Output for Struct is not turning out right!
 
Below is the output: Input the first numerator: 1 Input the first denominator: 2 Is the fraction positive? (Y or N): Y Input the second numerator: 1 Inpu...
[1 reply] : All of your if statements should have == instead of =. (by long double main)
Get outcome of a league fixture
 
Recently been asked to be a part of a C++ group project in Uni. The aim of our group is to be able to generate a football league table from a set number of fixt...
[5 replies] Last: A private mail has been sent @mats (by NandoHead)
question about passing a vector into a function
 
I have a vector that I want to pass into a function. However I keep getting the error message /tmp/ccxdV4vZ.o: In function `main': new.cpp:(.text+0xf6): un...
[3 replies] Last: Thanks guys, got it figured out (by wavebulb)
Simple Boolean function problem.
 
In the code below, when i put message(true); into the main function it outputs Hello,which i understand, but what i don't understand is why when i put in just m...
[1 reply] : http://www.cplusplus.com/doc/tutorial/control/ (by rich1)
Word Count and Rank
 
Hey yall, I'm trying to make a program that accepts a user string and then counts the amount of times that each appears. I've found that the basic word count...
[1 reply] : Any help please? (by lifeintechnicolorii)
Non-uniform collision
 
I'm writing a simple game with a Kinect camera. However, I'm unable to figure out how to check for collisions. The objects are rectangles and a depth map from K...
[1 reply] : (this may be deprecated) You could use http://www.opengl.org/wiki/GLAP... (by ne555)
How do I change the first letter to uppercase?
 
I need help with changing information in a file. This program access the file and changes the all uppercase sentenced to lower case. I used the tolower functio...
[6 replies] Last: Thank you. I think I get it. I'll give it a shot and let you know how ... (by musicman74)
PROBLEM OPENING FILE WITH FILE*
 
Write your question here. What I am doing wrong with these statement? FILE* pfile; pfile = fopen_s ("students.csv", "w"); #include <stdio.h> #inc...
[2 replies] Last: nvrmnd, An absolutely fantastic answer. I have learned so much. I n... (by phztfte1)
Switch statement, char counting two-character sequences
 
Exercise: Modify our vowel-counting program so that it counts the number of occurrence of the following two-character sequences: ff,fl and fi What I thoug...
[3 replies] Last: You probably should use a map/array for your counters and not a bunch ... (by giblit)
Pointer Newbie Question
 
Hello Community, i am a new member. Sry for my bad grammer. Here is my question: Why do i get a error message from eclipse when i type in int *poin...
[7 replies] Last: Ok. I hope i got it: int x = 0; int* pointer; pointer = &x; same... (by habakuk)
Deleting a char*
 
In my destructor I have it so that it will delete the char* buf, but after the destructor is done it's keeps on giving me a debugging error. If anyone could hel...
[1 reply] : [code firstline=6]String(){ buf = new char ; strcpy(buf, " ");... (by long double main)
by hwy63
Using structs in functions?
 
Hello, I am trying to create a program that uses structs to perform fraction multiplication. I need the actual multiplication to be performed in a function. I a...
[6 replies] Last: NEVER MIND FIGURED IT OUT! I have to put 'struct' in front of fractio... (by hwy63)
April 2014 Pages: 1... 3839404142... 67
  Archived months: [mar2014] [may2014]

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