Beginners - January 2016 (Page 2)

float variable won't print desired number of digits
I would like the output to print 4.0. When the program runs it prints 4. I've tried changing setprecision and changing float type to double, but no difference...
Jan 30, 2016 at 11:12pm
[2 replies] Last: You probably want to use std::fixed. cout << "Float is " << fixed <... (by Peter87)
How to make quicksort work properly?
Hey guys, I'm trying to figure out what exactly is needed to make this quicksort work properly. I am receiving an error saying, primary expression before ']' T...
Jan 30, 2016 at 10:56pm
[2 replies] Last: Thank you naaissus! It works like a charm, also thanks for the better ... (by C0D3FR3AK)
SOLVED
SOLVED
Jan 30, 2016 at 8:48pm
[2 replies] Last: If we add a little output in, it becomes clear at what stage the error... (by cire)
Whats wrong?
Hello. I need to write program, which would find the lowest element of matrix, find the line in which this element is and count average of this line. So whats w...
Jan 30, 2016 at 8:03pm
[1 reply] : So whats wrong with my program. Your indentation for a start. What'... (by kbw)
Find Syntax error in the program and rewrite program
Okay i am sorry at first place for putting question i know all of your time is valuable here please answer this question i got......... i know i should conside...
Jan 30, 2016 at 7:59pm
[7 replies] Last: Thats great Aryan403, you fixed the syntax errors :) but your program... (by Jaybob66)
by Zakusa
what do i need for making a game
hi what do i need for making a game i have visual studio installed and i have windows form application with a script already for making a window but i cant find...
Jan 30, 2016 at 7:29pm
[3 replies] Last: The you mentioned above is about the Windows API. There of course is n... (by Thomas1965)
Visual studio 2015 getline
Trying to write a parser and I keep getting stuck on this one part. I'm using visual studio 2015 and I swear either i'm stupid or visual studio is trolling me. ...
Jan 30, 2016 at 6:43pm
[6 replies] Last: Well thanks for the help everyone. One step closer to finishing this p... (by CrypticA1)
Help making a tree out of asterisks
I was able to write a code to make a triangle that looks like this: * ** *** **** }else if(shape == 5){ cout <<"\nHeight?: "; cin >> height;...
Jan 30, 2016 at 5:23pm
[3 replies] Last: That code works for the pattern of the tree, but I need it to match th... (by stealthboy)
Converting string to int,operators,etc.
This came up while i was working on my calculator and I trying to come up with an easier way to do it. Is it possible to convert a string, entered by the user, ...
Jan 30, 2016 at 4:17pm
[6 replies] Last: Whoa, speech to text is a little far out there. Also Dragon is a great... (by CrypticA1)
by MaryOz
Having issues with dynamically allocated arrays and memory leaks
Hey everyone. I'm working on some past papers for an upcoming C++ exam. Here's an exercise where you're supposed to fill in the blanks in order to avoid memor...
Jan 30, 2016 at 4:03pm
[7 replies] Last: Yes and that's the answer, that you have to make sure that every new h... (by MaryOz)
Invoke a default constructor from a non-default constructor?
I have invoked constructors before but it was always with inheritance. Suppose I wrote the following class Animal() { public: Animal() : legs(4), hung...
Jan 30, 2016 at 1:19pm
[2 replies] Last: Hi, An alternate view : Just thinking that a delegating ctor is hand... (by TheIdeasMan)
by y3y1f8
Checking strings with specific format
I'm trying to check a command string with a specific format. Following are the allowed format: 5n-3S+16ne2w +4ne1s3n NSEW is the direction (-3w is simply 3...
Jan 30, 2016 at 1:14pm
[1 reply] : Line 9 : Will never be true. If commands is not a digit it couldn't ... (by tcs)
Problem With CreateThread With A Function In Class [WINAPI]
Hello, I have a problem with CreateThread function from WINAPI in Visual Studio 2015 Update 1, i have a class and on this class i have the function which i n...
Jan 30, 2016 at 10:57am
[2 replies] Last: Thank you for your answer. Yes, my problem solved thanks to you. (by AliAssassiN)
by N8tiv
using namespace std;
Hello all, Definitely a newbie to C++, not to coding in general. I have very little experience with C#, but… I understand the basics of OOP; Inheritance, ...
Jan 30, 2016 at 9:32am
[2 replies] Last: Good stuff, thank you… Symbols? Haven't read anything on them, or d... (by N8tiv)
by m0bb1n
program stopping loop when finding specific number
Hello, I was trying to make a small program that stops running when it either finds 1, 2, or 88. When I run this number, the console is spammed with numbers...
Jan 30, 2016 at 8:08am
[3 replies] Last: Sure works man! And obviously it counts man. After my 1st lesson in sc... (by etrusks)
conio.h
Actually what is this? whenever i included this to a program, the compiler don't compile and conio.h is unknown header file. explanation please,
Jan 30, 2016 at 8:06am
[5 replies] Last: I see (by GibsRey)
Need Help (Noob)
Thank you for your help!! I finally got it.
Jan 30, 2016 at 4:54am
[3 replies] Last: WoW! That is exactly what i needed. I will go thorough and look at wha... (by curiousfloridian)
by ry23
Output File Existence Using fstream
My goal is to input the first line of a file into another file only if the input file exists and the output file doesn't. I have accomplished the status check o...
Jan 30, 2016 at 3:31am
[4 replies] Last: See 'Action if file already exists' and 'Action if file does not exist... (by JLBorges)
help with output and functions (1,2)
i need help with the output because im getting most of the information but some of it doesnt make sense?i think two of my function are wrong addwater which is w...
Jan 30, 2016 at 2:37am
[27 replies] Last: cool. enter width 15 enter depth 10 enter the flow rate in 20 enter ... (by Jaybob66)
---
---
Jan 30, 2016 at 2:24am
[2 replies] Last: now you've just got rid of a lesson for someone else! ungrateful sod! (by Jaybob66)
January 2016 Pages: 1234... 29
  Archived months: [dec2015] [feb2016]

This is an archived page. To post a new message, go to the current page.
Registered users can post in this forum.