General C++ Programming - March 2015 (Page 26)

Guessing Game
 
Hi guys! I'm trying to transform a code that has no bugs or anything, but I want to add on something. Here's the code: #include <iostream> #include <cstdlib...
[1 reply] : You can create a boolean. Call it bool option = true; Then do wh... (by TarikNeaj)
by BasV
global variables in cpp files
 
Hi everyone, Lately, I've been using more global variables declared in .cpp files instead of adding them as private class members. This way, I feel my classe...
[3 replies] Last: These are some good tips, thanks very much. I think I misused the word... (by BasV)
simplify function help
 
I am building a class fraction. I have it set up to take in two parameters such as fraction f1(4/10); and reducing it would be 2/5. I need to write a simplify ...
[3 replies] Last: never mind I figured it out. It does work, I just had put in my origin... (by UGAman22)
Writing a simple game, can you help me to organize it
 
Trying to make a simple 2D game on sprites Look my approach, I will appreciate your advices to make it any way better First: I have made Objects and Render_Obj...
[4 replies] Last: Is it legit that I not use sub-classes and virtual methods, and do ev... (by toad)
by Bako
does cygwin support visual c++ programming by qt?
 
does "Cygwin" support visual c++ programming by qt?? if does can you give me an instruction or link how to prepare necessary enviroment (i want to make visual a...
[1 reply] : No. See http://qt-project.org/faq/answer/do_you_support_using_qt_in_th... (by keskiverto)
Pig_Latin
 
// Good Morning I need help for this my project... // I didn't understand yet.. // main #include <iostream> #include <cstring> #include <cstdlib> #incl...
[1 reply] : Please use code tags: [co de] Your code [/co de] Read this: http://w... (by coder777)
by dkaip
regex ints capturing.
 
Hello. Assuming i have the ... 524. or 50 or another 6 and 10΄ or 3/4 or just 3 4/5 or 7 8/3% or 90% and final 8 hours. With std::wregex _int( L"\\b[^...
[no replies]
Radix Sort
 
I am want to code Radix Sort with buckets, It compiles and runs but is slower than QuickSort , I expected to be faster , and for sure I am doing something w...
[no replies]
Comparing String Indexes within a loop.
 
I am trying to compare corresponding string indexes one at a time within a nested loop.But I keep getting an error and a outcome I know I am not looking for. Ne...
[1 reply] : Note that one of my startWord string changes by one letter. Trying to ... (by amikecallies)
by toast9
Snake Game pieces following head problem free movement(no grid)
 
Hey, I'm trying to make a snake game with free movement. I've got the head of the snake moving about perfectly, but I'm having trouble with the math to make all...
[2 replies] Last: Let me get this straight, there will be a queue with a location far en... (by toast9)
Output is incorrect. Help?
 
Well I'm pretty new at using structs. I get the hang of it for other programs but I can't seem to get the correct output for this one. I'm using DevC++ for this...
[1 reply] : What is "correct output"? What output are you getting? What output ar... (by Disch)
c++ dll storing variable
 
I have a few questions about c++ dlls. So I'm pretty sure static variables are private to the dll and whenever they are loaded into the RAM, variables are initi...
[2 replies] Last: I figured that would be the answer... (by cmajor28)
Array Exerercise-Find top N values in array
 
Hey guys, So for a course I am taking I am have a question which asks me to do the following. Given: A two column txt file, with in the first column being s...
[19 replies] Last: @dhayden: I had not seen your post. I was merely commenting that most... (by kevinkjt2000)
Loop my program?
 
Hey guys, this is my second post. I am programming a simple K value calculator. What would be the most essential way to clear the terminal and start the progra...
[3 replies] Last: Damn it, you guys have been so helpful. Thanks alot!! (by YourBroAlex)
Help with a mastermind like program
 
I am trying to design a "game" where the user picks a number between 100 and 999 and the code will tell them how close their guess was to the actual random numb...
[no replies]
Need help with merge sort function !
 
hi, I tried to make a generic implementation in C ++, but I don't know how to create the "merge" function. someone to show me the program of the "Merge" funct...
[1 reply] : I think you need mergesort() to call a second function that does the w... (by dhayden)
Making functions of completed codes
 
I am trying to make 2 functions for 2 different codes that I had previously done. One of which is this. I am trying to make a function for prompting the questio...
[3 replies] Last: In your original code you should put the call to srand() outside the l... (by dhayden)
Odds and evens
 
I want to tally the number of odd and even numbers that i have in a file into a prototype. I already have the file open in a prototype call readData. so far i h...
[8 replies] Last: well the file has this numbers 25 41 58 96 42 52 63 47 85 96 100 58 9... (by matapexxxX)
How to print a certain line on a line in c++?(file handling)
 
I have this problem set and I need help guys. for example i have a file.txt with this contents: Employee Number: 14-6790 First Name: Kevin Last Name: Calib...
[4 replies] Last: okay sir thank you (by joken767)
learning c++ today?
 
hello guys i'm new in this group and i'm learning c++ programming .. but just confusing if should i continue it or not because i have read some articles on the ...
[5 replies] Last: From my experience the biggest failure while learning C++ is to give u... (by codekiddy)
March 2015 Pages: 1... 2425262728
  Archived months: [feb2015] [apr2015]

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