Beginners - February 2018 (Page 19)

Program Crashing
 
Hi guys! I am a beginner and I just started working on C++. I made this code but it has been crashing and I cant find the problem. Can somebody please help me. ...
[1 reply] : Really that program shouldn't even compile. If it does I suggest you g... (by jlb)
8x8 Checkerboard
 
Hey guys so I just started my 2nd computer science class. My issue is that my first computer science professor was a god awful teacher and spent 95% of the seme...
[3 replies] Last: Your checker board is actually a 2D array. Maybe read this first: htt... (by Thomas1965)
Game Library
 
I want to try to do visual novel game and I know that I need to use library to do it, but I dont know which library is suitable for this type of game. Can someb...
[no replies]
quotation marks in string
 
i need help with inserting double quotation marks for string . when i enter movie name . the movie name needs to show up in quotation marks. such as "Death G...
[1 reply] : Hello! A very good way to get the movie name surrounded by quotation ... (by Misenna)
pointer copy causes data corruption inside node
 
Hello. This is a frequent problem I encounter and I want to be able to figure out what is actually going on. I have a node class that has char and char* priva...
[no replies]
for loop question.
 
This is a homework question, but I need hints on how to complete it. We did not go over this in-class and I have searched the web and textbook for answers Th...
[1 reply] : Hi, The for loop consists of 3 parts: 1 The starting value 2 The en... (by TheIdeasMan)
Nested If..Else + And/Or operations in them
 
It's supposed to calculate the amount that the user input. I keep getting this error everytime: error: expected :primary-expression before '<=' token ...
[1 reply] : Hi, The expression is incomplete, you probably meant: if (loanAmt >... (by TheIdeasMan)
Swapping values in vector
 
So this assignment asks us to swap the third value and the last value of a vector if the length of the vector is >=3. Somehow my code isn't working. #include...
[6 replies] Last: never mind i got it. thanks jlb! (by barry23)
Multiple Read-file handling
 
Hi guys, I need a bit of suggestion on how to handle read from multiple files in a manner that best suits a program I am writing. The main idea of the program i...
[no replies]
About pointers to a double derived class
 
Hello forum, I have been struggling with this problem since a while. Basically I have a FunzioneBase.h that works like this: #include "Vettore.h" ...
[5 replies] Last: > I'm still working to get it run correctly, anyway I need those rando... (by ne555)
by Hex213
Point argument (vector argument)
 
Hi, I need to help with that word: "vector <point_t>& points". I don't know what I can write as an argument. void print_points(vector <point_t>& points) {...
[4 replies] Last: Thank you very much. You are god of programming. :-) (by Hex213)
by sharbu
Largest group formed by combinations of pairs - Java
 
Sample Input 1: 5 6 2 2 3 3 1 1 2 3 1 4 3 4 first line contains N and C. N is the identity number from 1 to N. C is no of pairs given in following C...
[3 replies] Last: #include <iostream> #include <fstream> #include <vector> #include <se... (by lastchance)
class vector, matrix 2D
 
How is a 2d matrix created from the vector class? help please. I need to know how I can have access to read the matrix and cout. #include <iostream> #in...
[1 reply] : the best way is vector<double> matrix(numrows*numcols); access via m... (by jonnin)
dynamic matrix
 
help please when I use void max_e_Matriz() appear very large values. #include <iostream> #include <stdlib.h> using namespace std; void dimMatriz(int&,...
[1 reply] : consider using notation. for(x = 0; x < a; x++) for(y = 0; y < b; y... (by jonnin)
vs2017 AND Fwrite
 
fwrite is giving me expression preceding parentheses of apparent call must have (pointer-to-) function strcat(t5c,"\\7zip.7z"); FILE *filedata...
[9 replies] Last: another dumb mistake for some reason the was a int fwrite=0; in my cod... (by nickhere)
What is the standard convention when creating multiple default constructors with the same arguments?
 
I am making a class in C++ and I need two default constructors with the same arguments. The only argument they need to take is a vector. Depending on the data t...
[12 replies] Last: @MikeyBoy, I just figured out how to do what I wanted using only one c... (by idknuttin)
Help with Do..While and If..
 
My code seems to be functioning properly but I can't seem to be able to make the terminating part pop up along with "-1" in the program when I input it. It keep...
[2 replies] Last: Ah, thank you so much! I think I understand how it works now. While s... (by Zelante)
Stuck at 4 in a row game, checking who is the winner
 
(First of all I am sorry for any miss spelled in my writting) Hello, I have been programming the little mini game 4 in a row, where i have 6 colums and 7 Row ...
[8 replies] Last: game_model.h: #ifndef GAME_MODEL_H #define GAME_MODEL_H #include <ar... (by globaltourist)
by cosimo
help on a function to compute quantiles
 
Hi! I have two errors from the code below at the lines starting with int idx: "invalid use of member (did you forget the &?)" and on the line starting with o...
[5 replies] Last: Thank you!!! (by cosimo)
special characters
 
int main() { char name ; cout << "please enter your password: "; cin.getline(name, 50); cout << "your password is " << name << endl; retu...
[1 reply] : 1. Use std::string . 2. Check each character 3. #include <cctype> and... (by Duthomhas)
February 2018 Pages: 1... 1718192021... 28
  Archived months: [jan2018] [mar2018]

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