
please wait
by loganc123
Reading data from text file into a dynamic array of structs
|
Hello, I am having some trouble reading my data into a dynamic array of structs. Below is my code as well as a copy of the text file. While debugging, I see tha... |
Nov 22, 2017 at 8:31am
[1 reply] : It's not a good idea to use eof() as the loop condition. It can caus... (by Chervil)
|
by daverave1212
How to fix this "Call of overloaded function is ambiguous" error?
|
I have the following simple code: template<class T> class myClass{ void print(string s){ //something } void print(T t){ //something els... |
Nov 22, 2017 at 8:04am
[3 replies] Last: #include <string> #include <iostream> struct some_class { // ov... (by JLBorges)
|
by daverave1212
Why doesn't my assignment operator overload work properly?
|
I am trying to create a String class like so: class String{public: string s; String& operator=(String a){ s = a.s; return *this;} String& operator=(st... |
Nov 22, 2017 at 4:58am
[3 replies] Last: @JayBari thanks, I didn't know copy constructors function like that. I... (by daverave1212)
|
by xxwendy3xx
What am I doing wrong!!
|
This is the problem A car dealership has 10 salespeople. The dealership keeps track of the number of cars sold by each salesperson each month and reports it t... |
Nov 22, 2017 at 4:33am
[1 reply] : try for (int i=0; i<10; i++) (by SamuelAdams)
|
by Hahang
Everyone help me fix this! I can not fix it! thank you so much
|
Write your question here. #include<conio.h> #include<stdio.h> #include<stdlib.h> #include<string.h> #include<stdlib.h> #include<windows.h> #include<math.h> //... |
Nov 22, 2017 at 3:57am
[1 reply] : See where you wrote, "Write your question here." Please do so. What pr... (by joe864864)
|
by sprajapat
Undeclared Variable In a Class?
|
Hey! I'm trying to use the get/set functions in a class to return a hidden variable, but keep getting the use of undeclared identifier in the getMinutes and get... |
Nov 22, 2017 at 3:53am
[1 reply] : Your get functions return "minutes" and "seconds" but your variables a... (by joe864864)
|
by phantomxman
Adding classes for weapon and armor in adventure game
|
I am asked to Make a hero class and add specific inventory slots for a weapon, armor, and ring. So far I have created the classes below but I am not sure how to... |
Nov 22, 2017 at 2:19am
[no replies]
|
by The hemporer
string manipulation
|
Hello, I am trying to manipulate a string (below). How would I put "John" in a seperate string, 1 in an int, 2 in an int, and 3 in a double? I figured out how t... |
Nov 22, 2017 at 2:02am
[1 reply] : std::istringstream input(s); //#include <sstream> std::string name; i... (by ne555)
|
by stonedviper
how to use std operators
|
Hello! As the title says how do I use std operators? I don't know if I'm doing something wrong or anything. But All i did is go by logic since std is a names... |
Nov 22, 2017 at 12:28am
[1 reply] : Never mind my mistake was not in this but in somewhere else and not in... (by stonedviper)
|
by agill
Beginner help with loop validation
|
I'm trying to create a program that asks a set of questions to determine what kind of tree a person is looking at. I'm new to programming and I'm having a hard... |
Nov 22, 2017 at 12:15am
[5 replies] Last: Oh wow, that's such a good idea. Thanks Joe! Now I've got a lot to wor... (by agill)
|
by donda97
May be a tough one
|
I have a code that acts as a login system. You can log into a computer, logout, search for users that are logged in, and then quit the program. The computer la... |
Nov 21, 2017 at 11:43pm
[2 replies] Last: Welp that solves it. (by donda97)
|
by daimkhalid07
Noob need help again!
|
hello respected members,l am learning c++ on my own and if anyone of you have known any best website,youtube channel or any book for learning cpp then please le... |
Nov 21, 2017 at 9:14pm
[2 replies] Last: I started with Michael Dawson's Beginning C++ Programming. It is a ni... (by JayBari)
|
by daimkhalid07
Noob need help again!
|
can somebody please eloborate me this code please? thank you so much in advance. #include<iostream> #include<conio.h> //using namespace std; // <---... |
Nov 21, 2017 at 9:10pm
[1 reply] : I am not sure specifically what you are asking, but I see in your prev... (by JayBari)
|
by jollyholly11
Help with nonstandard syntax
|
I keep on getting the error non-stand syntax; use '&' to create a pointer to member for the if (itemName == itemsToPurchase.at[&i]) and allItemsCount.at[&index]... |
Nov 21, 2017 at 6:45pm
[10 replies] Last: this is probably redundant as many others have pointed this out but th... (by adam2016)
|
by krreisys
Load dll from folder inside .exe
|
Goodday, i have run into a small problem. i have a simple program and dll file. Both are working perfectly. But when i try to load the dll when it is in a fo... |
Nov 21, 2017 at 4:49pm
[5 replies] Last: @thomas1965 @coder777 Thank you! It works now! The problem was that th... (by krreisys)
|
by bluefrog
assert a pair of integers in a std::array
|
How can I assert if two integers are valid given the following declarations: enum entry {empty, nought, cross}; class board { public: board(); // R... |
Nov 21, 2017 at 4:32pm
[2 replies] Last: What would be the most efficient method be for asserting if two inte... (by gunnerfunner)
|
by adam2016
switch statement compile time error
|
I'm trying to make a calculator that follows precedence rules,I'm following Bjarnes book anyway I get an error that I have never encountered before the error is... |
Nov 21, 2017 at 4:11pm
[3 replies] Last: that makes sense thanks =) (by adam2016)
|
by adam2016
program crashes reversing a string
|
not too sure why my program crashes here is the block of code causing the crash string first; cin >> first; cout << first.size(); string reverse; ... |
Nov 21, 2017 at 3:32pm
[6 replies] Last: very true sometimes there is no need to reinvent the wheel (by adam2016)
|
by lollos97boom
Problem with array program
|
I wrote this program for the college. The user must input 2 numbers (n,m) and the program must make an array with the size [n,m]. Then the user will fill the ar... |
Nov 21, 2017 at 3:19pm
[2 replies] Last: Thank you so much for your response. I will try what you said and i wi... (by lollos97boom)
|
by Bopaki
The second parameter in the class definition is an Array
|
I am not sure how to write in in my main() I get this error: C:\Martin\MalikChapter1\bookType23032016.cpp:166: error: expected primary-expression before '['... |
Nov 21, 2017 at 9:49am
[4 replies] Last: The std::initializer_list and its corresponding header #include <in... (by Chervil)
|