Beginners - August 2014 (Page 4)

Trouble with vectors
 
Hello, I'm teaching myself C++ and working through one of Stroustrup's books. I'm currently on the section of vectors, and am trying to write a simple progr...
[3 replies] Last: Thanks I'll give these a try! (by bwienand)
How to read from another file
 
Hi guys, I'm currently studying from the book "Accelerated C++" and am stuck in this exercise "Palindromes are words that are spelled the same right to left ...
[2 replies] Last: Ever think of downloading a dictionary file from the internet? Googl... (by AbstractionAnon)
Measure elapsed time for Bubble sort algorithm for multiple array sizes N.
 
Why is it outputting 0 as the time elapsed? #include <iostream> #include <time.h> #include <ctime> using namespace std; double BubbleSort(int , int ...
[1 reply] : Use the more accurate C++11 <chrono> library: http://en.cppreference... (by LB)
Pls explain this program.. How will executed??
 
Write your question here. #include<iostream.h> #include<conio.h> #include<string.h> class strings { char s ; public: strings() { s ='\0'; } strings(...
[12 replies] Last: @ Disch : Good catch, I somehow forgot that C doesn't provide overloa... (by Computergeek01)
How to find the common digits in two integer?
 
Suppose I have two integer number 4578 and 5908. Now I have to find the common digits for these two integers. For the integers given above the output should b...
[3 replies] Last: How many ways there are to do this? How many programmers are there?... (by AbstractionAnon)
Toggle feature. (includes SFML)
 
I have tried to make a toggle feature for a options menu. This is so when the user clicks on the sprite for the options menu it will bring it up. But the option...
[no replies]
moving an object.
 
hello i'm here again. just wanna ask. on how to move an object in c++ ? and also how to change a background color in c++ ? tnx. and Godbless:)
[1 reply] : What do you mean by move? And for windows console apps, check: msdn.mi... (by Aceix)
by reefa
Sorting random number array into primes
 
Hey guys, new to this site so sorry for anything im not supposed to be doing. I have just started c++ so still really dull with it. I have a assignment to progr...
[5 replies] Last: Managed to find some online chat and solved the mystery. this is the... (by reefa)
SDL
 
http://lazyfoo.net/tutorials/SDL/01_hello_SDL/windows/codeblocks/index.php i am following this tutorial but the libraries and programs have been updated since ...
[4 replies] Last: Thanks for the information guys, this wasnt so hard to fix. Bugs like ... (by ashtonr132)
Code-Blocks problems!
 
Write your question here. I'm a new student to coding and C++ language, and I'm using code-blocks as the school requires to use. I downloaded the mingw version...
[1 reply] : Would you show us the code? Otherwise it kind of sounds like a virus d... (by giblit)
by skkwan
Reverse string.
 
I have an idea for reverse string programme, but i don't know how to code it, i hope someone can help teach me and code it. So this is my concept : declare t...
[5 replies] Last: Thanks buddies! (by skkwan)
The program got error (Array)
 
The output should be like this ARRAY IS NICE TO BE USED & FUN TO PLAY! ARRAY IS NICE TO BE USED & FUN TO PLAY! ! ARRAY IS NICE TO BE USED & FUN TO PLAY ...
[1 reply] : Your current array size is 39 (with null). line 22 should be "NICE" no... (by giblit)
How to determine a second has passed since debugging.
 
I have been reading and editing many functions I found online to practice but to me, it is very difficult concept to understand in c++. I made progress to e...
[3 replies] Last: http://www.cplusplus.com/reference/thread/this_thread/sleep_for/ (by ne555)
by kni9ht
Trying to reorganize numbers
 
Thanks
[1 reply] : line 33: size should be size/2 line 35: 0 should be size / 2 You shou... (by Yay295)
merging and sorting 2d arrays
 
Hi I'm a beginner and I want to make a program that merges and sorts 2d arrays. I have a program, but when I run it the results are messed up #include <iostr...
[4 replies] Last: I don't want it hardcoded (by Dexter 3202)
by Mahkus
Loop for input
 
I have a question about input. I'm very new to C++ and I was wondering how to take input from the user until the user use Ctrl-d to stop. It's a very simple que...
[3 replies] Last: I've been busy all day and I just now got a chance to reply. Thank you... (by Mahkus)
by DevTK
Ambiguous calling the function using fstream C++
 
favorite I have a class, class A, with a data member std::fstream file. The class has a constructor that does not initialize the file. I get a comp...
[3 replies] Last: > I get a compiler error: > std:basic_fstream <_Elem, _Traits> ambiguo... (by ne555)
by Ch1156
Vertex array tile sprites (1,2)
 
Ok so I found out that drawing my tiles to the editor was a really bad thing to do because it created too many sprites and textures and draw calls that it made ...
[39 replies] Last: check your PM (by Disch)
Loop issue/question
 
Hello, I've been trying to learn using one of Stroustrup's books, and I'm running into an issue on one of the exercises. It asks to use a loop to write out a t...
[6 replies] Last: Instead of a b variable you could just do (int)a or static_cast<i... (by giblit)
Basic c++ math question
 
I'm doing a practice problem that gives me a function header, and a function and expects me to write the code. I'm given(assume lowestTerms is given): void ...
[9 replies] Last: How about od = ld*rd; , might that be better? (by Chervil)
August 2014 Pages: 123456... 40
  Archived months: [jul2014] [sep2014]

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