Beginners - July 2014 (Page 7)

Re start a program
 
Practicing my if/else functions with a simple number program that asks the user to input and carry out functions to a chosen number. If the user inputs the wro...
[8 replies] Last: you should use do while loop here. Here's the fix code #include <i... (by xenovia12)
by Ganado
Efficiency of public access vector
 
In the following example class A is defined below, and class B is some unspecified type (if it makes a big difference what B is, please say so, for now just ass...
[no replies]
Set terminal size in Linux bigger?
 
Hello Does someone know how to set the size of the terminal in Linux bigger using C++? I know how to do it in Windows, but not in Linux. Could someone he...
[4 replies] Last: ^Yes but if I don' t change it the text doesn't fully display, and I t... (by Nielyboyken)
confused in diferentiating between virtual functions and redefined functions
 
Hi there, i need some help on an issue am having as i try to understand the need to use the modifier (virtual) before a function am to use in a parent class in...
[4 replies] Last: thank you very much, lemmi try look it up (by closed account SECMoG1T)
by zionet
Generate N Perfect Numbers???PART II
 
The method of rapid generation ago by Euclid np=(2^(n-1))*((2^n)-1), n is number prime, that's what LOGICAL, but as I can handle 46 digit numbers ...? EXAMPL...
[1 reply] : I dont understand what you are saying or asking (by shadowCODE)
Non-const Ostream Object Overloading <<
 
Why can't os be const when overloading the << operator? You don't want to change os, right? ostream& operator<<(ostream& os, const Date& dt) { os ...
[2 replies] Last: Peter87 said it all (by shadowCODE)
reinterpret_cast
 
My goal here is to display the binary representation of a float in the console. The use of the bitwise shift right >> operator, seems to require an unsigned i...
[8 replies] Last: shadowCODE, you are converting the float to unsigned int and in th... (by squarehead)
by csharp
Range function help
 
Hello, I am trying to do this exercise for my next C++ class, I read the problem several times and still not sure what is required to do please can someone tel...
[5 replies] Last: Thanks you gilblit (by csharp)
Probably the simplest question you'll answer today.
 
so I have been fighting with this thing all week, and I'm finally closing in on finishing. However, I can not for the life of me get this function to display co...
[2 replies] Last: I knew it would be something simple. I can't believe I didn't see that... (by iandalton9690)
Student Class Compare Id
 
Write your question here. Hey everyone, I am writing a program that takes an input for students id (and several other things) and it has to compar...
[5 replies] Last: you should use any sorting algorithm like bubble sort or selection sor... (by shadowCODE)
What's wrong with my code?
 
Please help me fix my Code! Here's the problem question: Q. Create a class Date that has two integer members day and month. Create a default constructor and a ...
[1 reply] : #include <iostream> #include <cstdlib> using namespace std; class ... (by shadowCODE)
private variables in functions
 
without getting too into it, i need to access a private variable to use that number in a calculation. i have a function to return it, my question becomes if I c...
[4 replies] Last: Use BaseClass::getFunction() to get the private data from the base cla... (by shadowCODE)
by Jaycoh
Even sum of of multiplication table?
 
Hello all, first time poster, long time reader. Anyway, i'm at my wits end with this week's assignment. This assignment creates a multiplication table, then ...
[2 replies] Last: place the if(rows * columns % 2 == 0) statement in the body of the ... (by shadowCODE)
Sort Student's Names in Order
 
Hey guys this time I have to sort students names from input. I cannot use #algorithms so any ideas?
[5 replies] Last: Thanks I didn't you could use the > operator on strings. (by neel3123)
Why doesn't This Code Work?
 
Write your question here. Hey everyone. My code doesn't output the id in least to greatest order. Please Help. // Student Class.cpp : Defines the entry poi...
[9 replies] Last: Your welcome (by shadowCODE)
Something wrong with cin/sstream
 
I made a code that had a y/n option in it. I was wondering why after I press 'n', instead of displaying Enter name: (waits for person to input value for Nam...
[1 reply] : You shouldn't mix getline and cin . getline by default reads unti... (by giblit)
Help with simple program
 
Hi I am a complete beginner with C++ and I am currently experimenting to improve my skills. After doing Hello world and a calculator programm Im trying my ha...
[3 replies] Last: Those functions are uneeded. #include <iostream> using namespace std... (by Maharaja)
Play my game, check my code!
 
Hi, I'm a novice programmer hoping to be able to survive CS courses when I get into college. It would really mean a lot to me if you looked over my code and off...
[5 replies] Last: Alright thank you! I must have learned about them previously and just ... (by starskii)
I feel like I'm missing something obvious...
 
Alrighty, nothing special here... just trying to figure out what's up with the if statement in the code below. I've looked around, seems like I've formatted it ...
[6 replies] Last: Thanks! (by MI Wright)
Morse Code Translator
 
Hey, I'm working on an English to Morse Code translator and have encountered a problem I haven't been able to beat for awhile. The problem is when I run the cod...
[7 replies] Last: I tried it with the changes that whitenite1 made and it works like a c... (by senuba91)
July 2014 Pages: 1... 56789... 43
  Archived months: [jun2014] [aug2014]

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