Beginners - March 2015 (Page 10)

rng guessing code, error
 
Its the rng guessing game. When I run the code it seems like work properly. However, It just ends some times when i put the number below the rng created. for...
[9 replies] Last: I got it :D thanks guys (by qwertyking)
"Proper way" to terminate program to avoid error
 
I'm writing a basic class/program to manipulate matrices - say add/subtract/multiply. When adding matrices, the dimensions must be identical for the operation ...
[6 replies] Last: Sorted it. Like you said, beginners place catch blocks incorrectly a l... (by Greenfractallines)
Alternating something in a matrix
 
So basically I am supposed to present this 7x7 matrix and then off the the user to change part of the matrix. My problem is that when I enter start at [0,1] and...
[2 replies] Last: line 33, x<=lRow; line 35, y<=lClmn; (by anup30)
error: 'class Crc' has no member named 'table_idx_width'
 
This is my very first question here so I apologize if I don't get all the fancy formatting correct. The "Preview" button doesn't actually seem to work either so...
[3 replies] Last: Dang I hate refreshing the page each time. Thanks MiiNiPaa. :) (by Kimbluey)
Creating binary from array
 
Hello guys.I need to write a program that "transforms" the input array into a binary code.So far, so great.My only problem is that I know how to make it show th...
[4 replies] Last: http://www.programmingsimplified.com/c/source-code/c-program-convert-d... (by alexBB)
for loop help
 
I want to execute a for loop. All I need to is stop the program after n=5 and get the results of 1,4,9,16,25. I got wrong calculations. The square of 1 is 3. ...
[5 replies] Last: Yes, I am using C. And yes, it works. I also switched the statements ... (by sercandemir)
by sassy
Need help finding error!
 
Hello! I've almost completed my code, however, at the end it displays a strange number for number_1... not sure why. Any help would be great! Thanks! ...
[4 replies] Last: Wonderful. Thank you for all your help! (by sassy)
by Niore
Boost, Os X, Linker question
 
Hi. I have a question about compile programm with more what one source files. SRC/ main.cpp server.hpp server.cpp If i compile this i...
[no replies]
Weird bad access
 
I've got some really strange behaviour going on when I attempt to compile my code. What i'm attempting to do is build a matrix recursively that represents la...
[2 replies] Last: (col<N)?col+1:0); when col = N-1, you will try to access col == N, w... (by MiiNiPaa)
2d array [] []
 
hi guys i have an issues with my project. I have declared an 2darray filled it with random numbers and there is a task wehere I have to add to each element on t...
[10 replies] Last: you can do in several ways // send 2d array to functions #include <io... (by anup30)
problem in while loop
 
In the fuction given, can anybody explain how there is no condition in while but still it works. void concatenate_string(char *original, char *add) { ...
[8 replies] Last: Logical false is represened by "\0" According to keskiverto : ... (by alexBB)
Generating Random Number + Sorting
 
Hi, The below code compiles correctly to generate 100 random numbers, and then sorts them, first high to low, and then reverses this. While the program wo...
[1 reply] : if this is the most efficient way to do such a program or technically... (by MiiNiPaa)
Missing template arguments before '.' token
 
Anyone mind to explain why is it? D: Here is my header file of the linked list (Didn't post the definition. It's very long) template<class Type> clas...
[4 replies] Last: thanks a lot , Disch. I was wondering what type is it for the class no... (by DarkHeng)
Function overloading error
 
I am learning function overloading and i decided to make this simple program void add(int a,int b); void add(float a,float b); void add(double a,double b); v...
[17 replies] Last: thanxx everybody :D (by shadder)
Dynamic Matrix
 
Hi, please help; I want to put the row, where all the elements are prime numbers, in the end of the matrix #include<iostream> #include<cassert> usin...
[1 reply] : What does your lines 23-27 loop do? (by keskiverto)
unresolved external symbol
 
I am getting the following error in this program: Text1.obj : error LNK2001: unresolved external symbol "void __cdecl pop(int * const,int &)" (?pop@@YAXQAHAAH...
[3 replies] Last: If you want more specific compilers, program in java :p (by TarikNeaj)
if and else help
 
For my calculator program my if else statement defaults to the no result even if I type yes. Why is that? #include <iostream> int yes, no; char symbol...
[1 reply] : int yes ← yes is an int. It can only hold integers. If you will tr... (by MiiNiPaa)
by iluv41
getline function
 
I am stuck on my getline function. I need it to output to a delimiter, and it does store up to the delimiter, but it continues to output. This is the function...
[12 replies] Last: Oh my bad,didn't see that.:) (by TuiCall)
array bound is not an integer constant before
 
Please Help me When ever Getting error “array bound is not an integer constant before ']' token” ‪#‎include‬ <iostream> using namespace std; int...
[4 replies] Last: also, it is a good habit to call global var with scope operator std:... (by xenovia12)
invalid operands to binary expression
 
Hi I wrote this code #include <iostream> #include <vector> using namespace std; vector <double> somme(vector <double>, int); vector <double> s...
[1 reply] : What do you mean vector + vector means? Should it add respective value... (by MiiNiPaa)
March 2015 Pages: 1... 89101112... 51
  Archived months: [feb2015] [apr2015]

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