Beginners - September 2015 (Page 10)

by amar27
can someone please help me fix this!!
 
hey guys I am pretty new to the c++. I wrote this program which should ask me to input the diamond width and lateral offset and it should then produce a diamond...
[no replies]
Program has junk values even after input?
 
hello! so I was working on a contacts manager code, and it's working fine except that, my cmd stops working after I input 3rd contact and it's details, and t...
[2 replies] Last: I tried the vector method! Cmd stops working even after that! (by Shashank Setty)
input arrow keys
 
I'm trying to make a telephone directory. My idea is to print all the entries and scroll among them. But I don't know how to input arrow keys....... If someone ...
[no replies]
Undefined reference to
 
For some reason, every time I try to construct an array from my Vector class, I keep getting error messages |7|undefined reference to `Vector<int>::Vector(i...
[1 reply] : You cannot (non-trivially) place template implementations in source fi... (by MiiNiPaa)
by ebucna
syntax error in exercise about class
 
I have to make a program where a disc is being moved on a 10 * 10 grid starting at position (1,1). #include <iostream> using namespace std; class Gr...
[5 replies] Last: disc .x = 5; (by MiiNiPaa)
by Winsu
compiler
 
when I include the library iostream it says that no such file or directory, but <string>, < vector> it contains...what can i do?
[3 replies] Last: yes like that...but now I have realized about one thing...I got anew ... (by Winsu)
Are the methods in the <cstring> applicable for string class too?
 
I've tried out using memcpy() method to strings but was getting a "no matching function call" although it works perfectly when I use an array of char . Can som...
[1 reply] : std::string is not a c-string, so you cannot apply c-string operations... (by MiiNiPaa)
File Excistence Check & Rename
 
Hello, I am fairly new to C++ so maybe I am asking for the obvious. However, I am trying to write a C++ script for the Windows 10 OS which does the follow...
[5 replies] Last: Thanks a lot guys!! I am going to give this a try and will get back to... (by dominicnl)
by kalrin
Please help, really struggling!!
 
program that prints customer bill. if the customeNo starts with "0" he is eligible for a discount... i have no idea where to begin...do i use void functions? ...
[10 replies] Last: Unless your using references in your function you wont be able to pull... (by JamesDvorak)
truncating trailing 0
 
how do i make it so int a = 00001; output will still be 00001 not 1 std::cout << a; // outpus 1, expected output is 00001
[8 replies] Last: @Duoas sorry but thanks ive fixed it :) (by xenoviaquarta)
Math problem in dev c++
 
Here is the scenario: A local bookstore buys books at a certain cost from a wholesaler. The store then marks up the price by a certain percentage and adds sales...
[5 replies] Last: Study the code and figure out what it does #include <iostream> usi... (by progleo)
Cin input only number
 
Hello, I am working on an assignment and when executing my code I broke the program when I typed in a letter instead of a number. After doing some looking ar...
[3 replies] Last: @Yanson Thank you! That fixed it for me! Just removing the first cin ... (by EdWar82)
Table code
 
What is the write way to create a table using the header <iomanip>? I'm trying to use the code below but for the third line I don't get the line with the setfi...
[1 reply] : Here take a look http://www.cplusplus.com/reference/iomanip/setfill/ (by LendraDwi)
by nasser
scanf gives me Zero
 
This function is a simulator for an elevator But when the user enter the current_floor it starts from Zero not from the current floor void elevator_runn...
[10 replies] Last: ne555: Now I got it thx alot ,in addition I have tryied replaces the l... (by nasser)
Random Number Guessing Game
 
I have to create a program that is essentially a guessing game which generates a number from 1-100. The user has 5 guesses to guess the correct number. If the u...
[2 replies] Last: wwwwwwwwwwwwwwwwwooooooooooooooooooooooooowwwwwwwwwwwwwwwwwwwwwwwww!!!... (by lilmoe1967)
by LAplus
EOF Problem
 
Hi. Can someone help me to rectify the problem of my end of file? When I execute this problem, it cannot input the variables and I don't know what is the proble...
[6 replies] Last: #include <iostream> #include <string> int main() { bool a ; ... (by JLBorges)
Compile error
 
Write your question here. I need help with an error that is preventing from compiling my code. the error reads as: error: 'Jon' was not declared in this sco...
[8 replies] Last: That makes sense, I had gotten certain parts from my professor in a cl... (by shawnt1993)
If statement/While Loop
 
Write your question here. First of all. If I'm being overly newbie and this may have been asked. I searched for it, but had difficult with wording efficiency, ...
[1 reply] : http://www.cplusplus.com/doc/tutorial/control/ set limit to 7 set num... (by closed account 48T7M4Gy)
Four-Function Calculator Dividing instead of Multiplying
 
I'm trying to make a basic four-function calculator, and it seems to be working just fine... except when testing it, whenever I try multiplication the numbers s...
[2 replies] Last: Thanks so much, that was such a quick response and that was exactly th... (by MaryB1126)
writing to a file, content of an array, passed to a function
 
Program is supposed to write to user input and the roman numeral equivalent to the file "output.txt" in this form 1984: MCMLXXXIV which is the original user inp...
[1 reply] : Add a cout everywhere that you input, or calculating the value that is... (by SamuelAdams)
September 2015 Pages: 1... 89101112... 42
  Archived months: [aug2015] [oct2015]

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