Beginners - June 2015 (Page 11)

by Doge1
How to check string for any number?
 
What code to use to check string if any number are in there, if it is then return error.
[3 replies] Last: Or combine http://www.cplusplus.com/reference/algorithm/any_of/ and ht... (by keskiverto)
Default constructors variables.
 
Hi! Let's say I have a class that does not have a constructor. Does the compiler creates a default c...
[1 reply] : In short: it is safer to assume that compiler generated constructor do... (by MiiNiPaa)
tgamma function
 
Hello!I'm trying to use the tgamma function to solve this problem : https://www.hackerearth.com/may-...
[no replies]
by Doge1
Is there any way i could make this code simple as possible.
 
I need tit to be beginner friendly if anyone can help to make this simplistic as possible. #in...
[5 replies] Last: You're right, sorry. (by TheHardew)
I need help with a function returning the correct values
 
So I have an issue getting this function to work in my program for a summer course for C++. We a...
[2 replies] Last: THANK YOU SO MUCH I knew it was a super small fix that I was overlooki... (by Umahoin)
by ttu
Tricky increment example
 
Hi guys, I stumbled upon a tricky increment example recently. Here it is: int a, i = 0; ...
[6 replies] Last: [quote=2011 Standard] 5.17 / 1 [ expr.ass ] In all cases, the ass... (by MiiNiPaa)
calculator need help
 
trying to make a calculator just started learning c++ wats wrong with my code when i remove 3 functi...
[8 replies] Last: Could you please code tag the final version of your code. So any noob ... (by andywestken)
Switch Statements - Output Help!
 
Hello - This is my first post (I'm a total beginner!) but need some help. I've been working on an as...
[4 replies] Last: Perfect! Thank you so much! That worked. (by eiffel79)
by omurad
Modulo issue
 
...
[2 replies] Last: Makes sense... Good thing I posted this in the beginner category lol. ... (by omurad)
Read .txt file
 
Hi, i need some help in the following program: I have to read from a .txt file, that contains integ...
[2 replies] Last: How large are your integers ? If the numbers are small, like 1 - 20 t... (by SamuelAdams)
Static object member of the same class
 
Why is this code legal in C++? class myClass { public: int someInt; static myClass sub...
[2 replies] Last: Ah. It's all clear now. Thank you :) (by bheadmaster)
Initializing an Array of Strings
 
I am trying to write a simpler code to initialize my string array instead of having to enumerate eve...
[7 replies] Last: @MiiNiPaa Awesome. Thank you so much for the response!!! I understand... (by jhykima)
Question about cout << endl statements
 
How come in these line of code the endl code precedes the << string ;? Meaning why did the author o...
[6 replies] Last: Side note: endl is really overused. Just output a "\n" in the right ... (by Duthomhas)
Code::Blocks build fails
 
Learning C++ although I did some self taught hobby C programming a long time ago. First I started...
[3 replies] Last: If your tutorial recommend fstream.h, it likely is, as that isn't even... (by Zhuge)
problem with objects and classes
 
i have written down this program in codeblocks (gnu c++ compiler) using the concept of classes and...
[2 replies] Last: thanks very much newbiee999 (by kartik17)
Memorization Program
 
I am trying to make a program that takes file input from something in Latin "EcceGratum.txt" and the...
[3 replies] Last: To solve the max() problem add #include <algorithm> It must have b... (by andywestken)
Tons of Errors, Please Help.
 
What is Ostream Operator? #include <iostream> #include <ostream> #include <unistd.h> using nam...
[3 replies] Last: Line 37: what is logically wrong with cin << endl ; Line 13: Do you ... (by keskiverto)
by Nedim1
Output of a vector, why doesn't this work?
 
Why doesn't this code work? #include <iostream> #include <vector> using namespace std; in...
[1 reply] : i <= prime.size() should be i < prime.size() That is, you're pr... (by andywestken)
Funky string concatenation
 
Some weird stuff is happening when I try and concatenate strings and chars. For example, this is in...
[1 reply] : operator+, operator-, etc are evaluated left to right. So subterm cid... (by andywestken)
Classes questions
 
Alright so I don't know if there is a better way to go about this but I'm somewhat doing it like how...
[1 reply] : Line 41. This is not how to express what you want. What you should sa... (by booradley60)
June 2015 Pages: 1... 910111213... 32
  Archived months: [may2015] [jul2015]

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