Beginners - July 2013 (Page 51)

isdigit not working as I expected
 
Hello all! I have a specific code question. I'm trying to ensure that the character entered is a digit. If it is a digit, the program should continue. If it...
[6 replies] Last: Thank you very much KyleMiles, vlad and Peter87, that makes sense. Ch... (by programgirl)
Code Optimization
 
Hi everyone. I just started learning C++ last week on my own and have gotten to just before OOP in the tutorial on this site. I decided to start doing my own li...
[7 replies] Last: Alright awesome. I am thankful you gave me all the advice and help and... (by jmorales2012)
Finding the median
 
I am new to programming in C++. Can somebody show me how to sort this array so I can find the median. scores = {62,70,98,71,81,99,74,80,73,88,73,72,95,71}; ...
[3 replies] Last: You might want to post the code for the functions in question. The exp... (by cire)
C++ Recursion Problem help
 
Program to help select the treasures so that the total value of the selected treasures is maximized Input: weight_that_you_can_carry number_of_items wei...
[3 replies] Last: Perhaps reading this will give you an idea or two: https://en.wikiped... (by cire)
merging arrays
 
Hey guys. i need some help with my code so i am required to 1- Write a program that performs the following: a- Declares and initializes an array a of 10 intege...
[3 replies] Last: with reverse .... #include <iostream> using namespace std; int main... (by ajuzoo)
Program doesn't operate properly
 
I've got a quite challenging problem here. I've made a function with the purpose of splitting number's digits by half, something like this: 123456 --> 123...
[6 replies] Last: btw, why don't you use string ? you can split them by first knowing t... (by chipp)
Understanding...
 
Write your question here. #include <iostream> using namespace std; void drawrectangle(int l, int h) { for(int line(0); line < h; line++) {...
[7 replies] Last: That is exactly right and you can increment by more than one at a time... (by Lostsoulparty)
I need help with saving. (may be an obvious solution)
 
I am sort of a beginner to c++ and know basic console items and functions. I need help with a text based game where the problem is saving. I know how to save ...
[2 replies] Last: Alright. Thank you! (: (by WIT Sorcery)
Some assistance for a newbie doing it from a book please
 
I am just starting out on the path to C++ and have got a book called C++ through game programming third edition. I cannot get past the very first topic as thing...
[10 replies] Last: The problem I think I'm experiencing is I don't know which are C erro... (by MikeyBoy)
what wrong with my code?i cannot compile
 
#include<string.h> using namespace std; class marks { private : char name ,grade; float gpa; public: void marks::set_name(char n...
[6 replies] Last: @glibit: string.h is not the same as string. string.h becomes cstring ... (by closed account Dy7SLyTq)
by maebe
Binary Tree Operations
 
Hello, I am getting a strange error: "Assign6(33183) malloc: *** error for object 0x7f9d2a4038e0: pointer being freed was not allocated*** set a breakpoin...
[3 replies] Last: Ah, I see EXACTLY what you're talking about. I bet that will fix the i... (by maebe)
sizeof operator machine dependent?
 
Hi all, I am a beginner in C++ and I have a doubt regarding the memory system. #include <iostream> using namespace std; int main(){ cout << sizeof(int) ...
[7 replies] Last: Thanks you all who came forward to help me. I think that It is clear t... (by Himansh)
About char, int and double
 
Hello guys. I'm currently learning alone about c++. One thing I've learned is that the most common basic types available to me are char, int, and double. A vari...
[6 replies] Last: @djronix: here's it #include <iostream> using namespace std; int ... (by Himansh)
by xiuuao
C++ operator and pointer question.plz help me
 
%=, >>=, <<=, &=, ^=, |= what do these operators mean? And what are the functions of these operators? And also in the C++ tutorial provided in this website...
[7 replies] Last: Do you have any c++ book..I'm sure they are in there..if not u can alw... (by closed account EwCjE3v7)
Cannot subtract values from elements of a vector
 
Hello, I would like to perform an operation with vectors, but I lost my way. Help would be appreciated. The operation is, vv = v -(alpha +1)*i; where v a...
[5 replies] Last: Indeed it works, thank you very much! (by ranittan)
Cin.spacething();
 
Hi, I'm just wondering if there is something I could use that is like cin.get(); but for the space bar instead of the enter key. Thanks!
[2 replies] Last: Thank You! I did not know that! I have been doing c++ for a year now a... (by Perry Turner)
Finding Capital Letter
 
I've made a function that finds the capital or lowercase letter of a letter that was entered, but I find my function too long, and I wonder if there is any shor...
[8 replies] Last: Now I get it :) Thank you for your explanation. (by GoranGaming)
Help understanding code for traversing a file
 
Hello, I found some code online somewhere for a project I was doing that allows you to read all the files in a certain file directory, however I don't really un...
[3 replies] Last: code for traversing a file Actually, what you're showing is code to... (by andywestken)
While loop
 
Write a program that uses while loop to perform the following steps: a. Prompt the user to enter first number and second number. (First must be less than seco...
[1 reply] : first of all... thats java in a c++ beginners section... secondly do u... (by closed account Dy7SLyTq)
how to use a loop in Functions
 
can Anybody guide me by writing any program, that how to use loops inside a functions...
[3 replies] Last: @Zeroes http://www.cplusplus.com/forum/beginner/105330/#msg568417... (by giblit)
July 2013 Pages: 1... 4950515253
  Archived months: [jun2013] [aug2013]

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