Beginners - May 2013 (Page 31)

Finding characters in strings
Hello guys i'm new to this forum and to programming in general. So for school I'm supposed to compile a program that takes a user input into a string, and then ...
May 16, 2013 at 4:27am
[1 reply] : If you are speaking about standard class std::string then you can use ... (by vlad from moscow)
Strings `find` function!
Hi, let`s say I input a series of strings separated by 4 spaces like: string x="Hi my name is bob"; i know if i do this: x.find(" "); it will give me the nume...
May 16, 2013 at 4:18am
[2 replies] Last: for ( std::string::size_type pos = x.find( ' ', 0 ); pos != st... (by vlad from moscow)
Help fixing an infinite loop
I'm trying to write a function for checking whether the user wishes to continue, and then another function to check whether the input was valid. For some reason...
May 16, 2013 at 3:07am
[3 replies] Last: Thanks guys! That got it working! (by sadistic)
SYNTAX- I'm a beginner and need some help.
I set out to make a Random number generator. I am still new to C++. I made my first random number generator, then tried making it a different way, and then ano...
May 16, 2013 at 2:42am
[11 replies] Last: My code generates a random number from 1 too the int variable, which r... (by Rougeace4)
by ECE07
conio.h in visual studio
Hi, I wrote a simple program in Visual Studio 2012 to add 2 and 3. The program will not run without "conio.h" and _getch();, the exe window disppears as soon as...
May 16, 2013 at 1:07am
[7 replies] Last: Better yet Keep the console open long enough to see your program's o... (by Duthomhas)
stuck on prime numbers
So, I am trying to find prime numbers between 1 and 100. I know what prime numbers are. I am using this technique to come up with the prime numbers: a) I wil...
May 16, 2013 at 1:04am
[14 replies] Last: http://www.cplusplus.com/forum/beginner/101355/ (by eyenrique)
novice
Hi guys this is a really simple code , but I keep getting this error for line 16. PLEASE HELP. // Listing 2.2 using std::cout #include <iostream> ...
May 15, 2013 at 11:24pm
[4 replies] Last: Thanks bro this is the second program I ever wrote. A computer progra... (by zopticalz)
by giblit
Simulation problem (1,2)
I am making a simulation program based on some old forum topic that I thought would be interesting to try and make it 100 shooters instead of 3 and to have the ...
May 15, 2013 at 10:47pm
[26 replies] Last: Output continued: Gunman 43 has 1296051 kill(s), 1000000 death(s), an... (by giblit)
string class with pointers?
so im trying to write this code that will display value of the pointer (not the address) of the parameter to the monitor. i can get it to work with c-string...
May 15, 2013 at 10:19pm
[2 replies] Last: Thanks got it to work (by ninthred)
by Aceix
Usage of reference operator
When something like the below is done, what does it mean? const sf::Texture& texture=font.getTexture(); //font is type sf::Font, and sf::Font::getTextur...
May 15, 2013 at 9:51pm
[5 replies] Last: Talking about the usage of the & operator in "sf::Texture&" In this... (by andywestken)
Linker Error!!
I have a linker error in my two functions and I cant figure out why. Could you please help me. The error is this: Undefined first r...
May 15, 2013 at 9:46pm
[8 replies] Last: float was a requirement by the spec sheet i was given otherwise double... (by TECKSPEED)
by xsxs
array help!
Hi! I recently began learning arrays and I was wondering if someone was able to help me with the question below. Declare a two dimensional 5 by 10 array and ...
May 15, 2013 at 8:42pm
[5 replies] Last: ok, thanks for your suggestions but i have tried and it my code still ... (by xsxs)
C++ Win32Api
Hello, I am beginner to WIN32 API library, I am using Visual Studio 2012 Express, and I just created win32api file with precompiled header. Before that i ...
May 15, 2013 at 8:01pm
[3 replies] Last: I think that you simply skipped the statement where the msg is defined... (by vlad from moscow)
c++ sudoku
hey guys.i must write a sudoku with c++ but i havent got enough information i learning new is there any one help me ?
May 15, 2013 at 7:23pm
[2 replies] Last: no solver its just sudoku game (by Omer Can)
please help me !!!
#include <iostream> #include <string> #include <numeric> #include <functional> int main() { std::string s1 = "agatgctagatttcg"; std::string s2 ...
May 15, 2013 at 6:47pm
[3 replies] Last: thankyou so much, you save my life. (by zzh0008)
Finding words that begin with specific letter
Hello The program starts out with the user inputing a few words like food table fast computer life fear then it's supposed to find the words that...
May 15, 2013 at 6:15pm
[4 replies] Last: The reason this works is because a std::string is really just an array... (by giblit)
Arrays
Hey so I am in a class where we are using Microsoft C++ and right now we are working on a program using arrays. We are given a problem where we have to sort peo...
May 15, 2013 at 5:34pm
[2 replies] Last: #include <iostream> #include <conio.h> using namespace std; int... (by beginnerstudent)
best way to save and encrypt data?
i have a program that currently saves and encrypts data in a database. but is there other ways to save data and still encrypt it?
May 15, 2013 at 4:25pm
[2 replies] Last: Or a txt file and save as text if you are encrypting a txt document (by giblit)
Need some help
I'm completely new to programming, and I'm using a book called 'Accelerated C++' by Andrew Koenig and Barbara E.Moo. I'm trying to make the program Hello World...
May 15, 2013 at 4:15pm
[4 replies] Last: He's doing it the faster way not including every std namespace but ins... (by giblit)
Need Help!! (1,2)
I need to know if this code will compare two values in arrays at the same index and if it is above a certain value assign True to a third array and false if oth...
May 15, 2013 at 4:07pm
[31 replies] Last: I redid my functions for that part of my program because I was confusi... (by TECKSPEED)
May 2013 Pages: 1... 2930313233... 66
  Archived months: [apr2013] [jun2013]

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