Beginners - November 2016 (Page 18)

by jo123
How to create a map to insert elements based on an event
 
Hello All, I need a help to create a map of vehicle ID, pedestrian ID and its corresponding distance from vehicle and then to find the minimum distance for a p...
[2 replies] Last: Thank you, I am trying that. (by jo123)
by braie4
GPA calculator
 
I have a working program, but when I go through it the code will not calculate the GPA. It won't show the GPA after it is compiled. Can you explain to me what I...
[5 replies] Last: No, I'm asking what you input for coursenum on line 75. It might be h... (by koothkeeper)
Overloading operators
 
So I wrote some code so using std::cout I can print out an object of my own class. Like std::cout << myObject . #include <iostream> class Class { priva...
[9 replies] Last: I thought you couldn't explicitly call the constructer and only when ... (by Chervil)
Ceasar cipher
 
So I want my code to just encrypt the first 5 letters, but I get error message Too many arguments to function call, expected 0, have 1. On line 13. #include ...
[5 replies] Last: String function length() does not take any parameters. http://www.cp... (by Chervil)
Hello
 
Hi guys i'm new to this forum
[1 reply] : Welcome! That was short, haha. #include <iostream> int main() { ... (by boost lexical cast)
Create a define from a define
 
Am I able to create a #define from a different #define macro. And if I can, is this bad practice?
[1 reply] : Am I able to create a #define from a different #define macro. Yes. i... (by coder777)
Parking Space Program
 
Hi, I am a fairly new c++ coder and am being asked to create a program that will track use of a parking lot. There are a fixed number of spots and there are le...
[no replies]
Adding on a suffix to a file
 
So I need to add the suffix .radar onto a filename taken in by a user. I am at a loss on how to even start to do that, this is my code so far. #include <i...
[2 replies] Last: Thank you for the early christmas present (by Sampl37)
Nested for loops
 
So I have a nested for loop here, what I need to be able to do is have each row do something else, but have there be a total of 5 rows and 5 columns. Every vide...
[2 replies] Last: This is what I finished with: #include <iostream> #include <conio.h... (by muffsez)
Two dimensional array, output different with my prof's
 
Hello guys, I'd like to ask for your assistance from you guys on my C++ lab. The code main objective is to interpolate between each pair of numbers(both horizon...
[1 reply] : This is the test that I made using the exact input my prof gave. When ... (by iSquall17)
LINK 1109 error?
 
Just been getting the hang of using header files with classes and decided to check some values, and got an error stating cannot remove file 'C:\Users\myuser\...
[1 reply] : Realized I said damage at level 50 instead of 25, minor thing though f... (by moosyman)
Convert single character string to char without use of an array
 
I'm trying to convert a single character string into a char. I would rather not have to use an array to try to keep the code simpler. Is there a method for c...
[1 reply] : assert(string.size() == 1); char character = string ; (by helios)
by Tantum
Someone help me choose a compiler!!!
 
Hello guys, I am now forced to do a C++ assignment that is not for Windows OS. The code given excessively uses features that I believe they are only availabl...
[5 replies] Last: [quote=Tantum]I do not want a command line compiler!!! I want somethin... (by mbozzi)
How to load strings into dynamic array and concatenate them?
 
Write your question here. #include <string> #include <fstream> #include <iostream> using namespace std; int main() { ifstream infile; int index ...
[2 replies] Last: Dynamic arrays are somewhat misleading because a fixed size still has ... (by gunnerfunner)
Clarification on question
 
Just wanted clarification that I did what this was asking, as it's for homework. The code runs, compiles, and displays what is intended. I'm just not exactly su...
[16 replies] Last: p.s. Another advantage, apart from improved legibility, is re-usabili... (by muffsez)
by egio
What is my assignment's output?
 
Hello, I was given the assignment below, but I have no idea what the program is even supposed to do. I wrote some more questions below the assignment. Thanks...
[6 replies] Last: Awesome! Thank you so much! I finally have somewhere to go! :) (by egio)
Library Help
 
Im trying to make a simple library but im getting a lot of errors when compiling. this is what i have so far. #ifndef my_library #define my_library ...
[1 reply] : well you may start with a struct (or class maybe) http://www.cplusplus... (by shadder)
by Kimmy1
Loops and average
 
How would I create a program that allows the program to choose which loop they want to use to enter 5 integers and calculate the average. The program should hav...
[7 replies] Last: use arrays for the 5 numbers, then you can use loops in the program fo... (by shadder)
by Bukk
list iterators incompatible error
 
Hello, I'm new to iterators in C++ and I'm facing problem with incompatible iterators. I've spent on this over 7 hours and still I can't figure out why it's not...
[1 reply] : void Prostredi::iterator::operator++(int) { iterator co... (by cire)
Functions returning odd values
 
I've been looking through classes and been trying to organize material as best I can, so I have started setting up values in functions contained in classes. Whe...
[2 replies] Last: Thank you so much, solved the problem. (by moosyman)
November 2016 Pages: 1... 1617181920... 44
  Archived months: [oct2016] [dec2016]

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