Beginners - October 2016 (Page 8)

passing char[256] by reference and wanting to cout the result
 
I am trying to pass a char by reference and cout the results void display() { int month = 1; char nameOfMonth ; displayMonth(month, nameOFMonth); ...
[3 replies] Last: Thank you for the help! This made my program work. Thanks for the he... (by roxanetd)
by muftah
Problem with Visual C ++ visual
 
//This message appears when I run the program. Error 1 error C4430: missing type specifier - int assumed. Note: C++ does not support default-int h:\prog\co...
[7 replies] Last: More so: You calculate z before x and y have values. Move z = x +... (by coder777)
While loop input read starts at second value.
 
Hi all! Brand new to this stuff but having a ton of fun learning. Here is my professor's comment about my latest project. "After the validity of the input ...
[2 replies] Last: I had thought about that for average. Ya average should definitely be ... (by Angrboda)
by Sp1ke
Matrix class operator overloading
 
Hi Guys, I'm trying to learn about classes and operator overloading. I took this code (also from this forum as a basis and changed some stuff around: http://ww...
[2 replies] Last: Great, problem solved!! Thanks so much!! (by Sp1ke)
split vs conjoined operators
 
So I'm looking at what I *think* is a typo in my textbook and a half hour on Google can't give me a solid yes/no either way. We're looking at operators that ...
[4 replies] Last: @keskiverto Thank you! Never heard operators clled tokens, but it mak... (by propogrationdragon)
While loop question
 
I'm using some functions to pass around the value string shape is holding, I had my if statement checking to see if the valid input was entered in to the loop t...
[10 replies] Last: That makes sense, I was thinking about that while I was writing it see... (by muffsez)
Redefinition of 'struct tm' error. Header issues
 
I've just been copying and pasting my headers to each .h and .cpp file. Guessing this is wrong. Do i need to include guards somewhere? or which headers need to ...
[6 replies] Last: However, if you do need the <ctime>, etc, put them first: Putting st... (by cire)
Inserting a node in a linked list using recursion
 
Can anyone explain how to insert a linked list using recursion? I found this code online, and cannot figure it out. struct node *insert(struct node *p, in...
[3 replies] Last: The code was found in a dark and possibly forgotten corner of the inte... (by Nico)
Help!!! I can't get the right output
 
Hi all, I'm doing a program which Ill post the criteria below. I need to get it to say how many world series they won but it keeps coming back with 0 for every...
[8 replies] Last: Do you run to program from your IDE or do you start it directly? I don... (by Nico)
dereferencing NULL pointer in queue
 
My program crashes when the show function is called for the second time. I'm pretty sure its an issue of the NULL pointer being derefrenced. The problem is, I a...
[6 replies] Last: Peter87, marvelous. That was exactly the problem. Thank you man. Much ... (by KenBoneSlice)
C-String Functions without using <cstring>
 
Hello, I've written 6 different c-string functions as shown. My problem is that program does not continue after the myStrCpy call and does nothing in the ter...
[6 replies] Last: Thank you very much for your help! It seems I was confused about how c... (by jokerren)
by CTLZ
storing multiple values of x and y
 
i am suppose to use the values of x and y to calculate area and etc, but how to i store multiple values of the same variable x and y into the same element in my...
[1 reply] : Not really sure what you mean by multiple values of the same variable... (by lastchance)
resize() doesnt work help
 
i use code blocks and resize function does nothing whenever i return the value of a it doesn't give me the address nor the error but gives me the number 6 ...
[4 replies] Last: thank you so much that helped (y) (by zeroblank)
Converting decimal number to octal,binary,hexadecimal appears backwards.
 
I have to write a program that converts a decimal number to a binary,octal, or hexadecimal number. The number are coming out correct but backwards. Like if the ...
[1 reply] : As you are going to derive the digits from the right, but write them b... (by lastchance)
Deque container assignment
 
This is my code for an assignment that I am currently working on: "2a. Write a function to add first 6 integers alternately to front and back of a deque. (in h...
[1 reply] : The main() function must be defined as a normal function. It's not all... (by Peter87)
Help with while loop please
 
Write a C++ program using the while loop to calculate when the population ceases breeding and thus dies out.You do not have to input any values. birth rate = ...
[7 replies] Last: As someone said before, to use birth_rate and dead_rate and not having... (by Ciplas Plas)
Trouble Multiplying Matrices
 
Hello everyone, new to this site. Basically, I am trying to multiply 2 4x4 matrices in the following form: AB and BA . Now, I think I managed to get ...
[4 replies] Last: Thank you guys. :) (by Maima Van Persie)
dealing with integers
 
am working on encryption and would like to select and modify individual members of say a four digit integer. I achieved that with an array but would be glad if ...
[4 replies] Last: It can't be done easily using decimal digits, but it's extremely easy ... (by mbozzi)
by MSG
Confused a bit
 
Create a function that returns positive only whole numbers and has arguments to pass in a 2D array, the number of rows, a number to look for in the array, and t...
[4 replies] Last: Is this correct? int Function(int ar , int size) { int ROWS = 0; ... (by MSG)
Voting simulator in c++
 
I'm trying to tweak this template to have the '*' output instead of the percentage. #include <iostream> #include <string> using namespace std; void...
[2 replies] Last: It's supposed to be a voting simulator lol (by aqmorgan12)
October 2016 Pages: 1... 678910... 51
  Archived months: [sep2016] [nov2016]

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