- Strength to Increase Rep
- +7
- Strength to Decrease Rep
- -1
- Upvotes Received
- 9
- Posts with Upvotes
- 6
- Upvoting Members
- 7
- Downvotes Received
- 6
- Posts with Downvotes
- 1
- Downvoting Members
- 6
Did 6 years in the military (navy), jumped into school, I work a steady job as a janitorial professional (thats right I said professional). I have one wife, two kids, and three computers.
- Interests
- watching New Orleans Saints football, sleeping in my oven, howling at the moon
96 Posted Topics
Re: Don't know how useful this is to anyone else, but I made a pdf set up for easy reading on my Irex Iliad digital book reader. I'm sure some of you have some Kindles or Sony Readers or whatever. Anyway, here you go, my pdf I made of Narue's post. … | |
Re: [CODE]//Namespaces needed using System.Diagnostics; public bool FindAndKillProcess(string name) { //here we're going to get a list of all running processes on //the computer foreach (Process clsProcess in Process.GetProcesses()) { //now we're going to see if any of the running processes //match the currently running processes by using the StartsWith Method, … | |
Re: dis: [CODE]for(int i=0; i<5; i++) { for(int j=0; j<5; i++) cout << "*" cout << endl; }[/CODE] | |
Re: If you're in windows (like using visual studio 2005) then just use [CODE]system("PAUSE");[/CODE] If you're on a Unix console, you really don't need a pause after you run your code. The snippet above may be useful for pausing at different times other than after the code runs, to run the … | |
Re: Take a look at Game-maker.. It is more geared toward drag and drop and 2d rather than 3d but it can be fun to toy around with: [url]http://www.yoyogames.com/make[/url] | |
Re: [CODE][B]if number < smallest smallest = number[/B][/CODE] | |
Re: So eh... when you're calling your deal here [CODE] QuickSort(&test);[/CODE] with your 20 element (size) and then you're doing this [CODE]int Low; // The left end. int High; // The right end. int Pole; // The pivot. ... int Size=RawData->size(); // Get the size of the vector to be altered. … | |
Re: This is C++'s scope resolution operator. This resets the scope of that variable in this case. You see this all the time when you declare a class and then implement its functions elsewhere. For example, you have [CODE] class myClass { int myFunction(); }; int myClass::myFunction() { ... } [/CODE] … | |
Re: This isn't a bug in VS if that is the question. Is there any reason you are insistent on using an unsigned short for your loop control variable? It would be much simpler to just use a plain old int | |
Re: 5 factorial: 5! = 5 x 4 x 3 x 2 x 1 = 120 4! = 4 x 3 x 2 x 1 = 24 15! = 15 x 14 x 13 x 12 x 11 x 10 x 9 x 8 x 7 x 6 x 5 x … | |
![]() | |
Re: Set your x and ctrl to whatever you input for inpt. Then you can run through ( ctrl > 0 ) and output x like [CODE][B]while X is larger than zero then print X subtract one from X endwhile[/B][/CODE] Decrement your ctrl counter and set X equal to ctrl and … | |
Re: can you post the code you are using to decode the bmp? | |
Re: You may find " [URL="http://msdn.microsoft.com/en-us/library/9yd93633.aspx"]Linking an Executable to a Dll[/URL] " from MSDN helpful. Depending on what version of VS you are using (this is for 2008): You can got to Project Settings > Properties > Configuration Properties > Linker > Input Under Additional Dependencies add "Fmod.lib" to anything that … | |
Re: [URL="http://www.daniweb.com/forums/post56470.html#post56470"]This post[/URL] may or may not be helpful. :) | |
Re: Not only that semi-colon but also look at your braces in your function: (I marked things in red) [CODE]void final_grade(grades& the_grades)[B][COLOR="red"];[/COLOR][/B] { cout << "Enter the score of the first quiz: "; cin >> the_grades.score_quiz; cout << "Enter the score of the second quiz"; cin >> the_grades.score_quiz2; cout << "Enter … | |
Re: Get the coordinates of the cursor relative to the entire screen. Then use something like GetWindowRect to grab the coordinates of the game window. Then from there it should be easy to perform a simple conversion to get the mouse coordinates relative to the game window Reference: [url]http://msdn.microsoft.com/en-us/library/ms633519(VS.85).aspx[/url] | |
Re: [QUOTE=dflatt;1329008]the question was the title so can there be multiple getters to one setter?[/QUOTE] Theres absolutely nothing wrong with setting all three in one function and then having independent get functions for each one. Cheers ! | |
Re: You're on the right track, but you're not getting the prime number part correct. Try re-writing the inside of your while loop and remove the cout << numbers after the loop, as you wouldn't want to print anything there in other words [CODE=C++] #include <iostream> using namespace std; int main() … | |
Re: Well here in the MODE: [CODE=C++]//MODE int x; int freq = 0; frequency = new int[freq]; for (int count = 0; count < stdSurveyed; count++) { x=students[total]; frequency[x]++; } cout << "The mode is: " << mode << endl; [/CODE] You are outputting mode without doing anything to modify it … | |
Re: [url]http://www.boost.org/doc/libs/1_44_0/more/getting_started/index.html[/url] [url]http://www.boost.org/doc/libs/1_44_0/libs/multi_index/doc/examples.html[/url] [url]http://msdn.microsoft.com/en-us/library/aa288739(VS.71).aspx[/url] [url]http://www.gamedev.net/community/forums/topic.asp?topic_id=553798[/url] Source: google.com | |
Re: Here is what it looks like when I run the code: [CODE=fortran]Please enter your first name: Blake ********************* * * * Hello, Blake! * * * *********************[/CODE] What are you having trouble with? | |
Re: Try installing the VC++ 2010 Runtimes [url]http://www.microsoft.com/downloads/details.aspx?FamilyID=a7b7a05e-6de6-4d3a-a423-37bf0912db84&displaylang=en[/url] | |
Re: I read a book a couple of years ago with tons of great tips for creating well structured code called Code Craft: [url]http://nostarch.com/codecraft.htm[/url] It was really a great read and worth a look if you're looking for ideas on what is generally considered "good" programming practices. | |
Re: [CODE=C++]// result of the operation when addition is chosen resultAdd == firstNo + secondNo; cout<< "the sum of the numbers are ->/n"; cin >> "resultAdd";[/CODE] Just a couple of little errors here: 1. you used == in place of the assignment operator = 2. the cin >> "resultAdd"; line is … | |
Re: A pyramid such as that grows at a rate of (2x - 1), or one less than 2 times x. [code] ***X 2*1 = 2 -1 = 1 **XXX 2*2 = 4 - 1 = 3 *XXXXX 2*3 = 6 - 1 = 5 XXXXXXX 2*4 = 8 - 1 … | |
I am having trouble finding out info regarding how to stop my application from "Beeping" every time I change focus with the "ENTER" key. For the sake of clarity here is the specific action and code which produces a sound (which I want to eliminate): I am simply trying to … | |
Re: When I want to thoroughly test something I take it one TINY step at a time, but that might have a lot to do with my OCD :D I would worry about the first step, ensure that works fine, then move on to testing the rest of them, rather than … | |
Re: try returning ' ' instead of " ", don't know why but something tells me it might work | |
Re: [code] define total = 0 define array[n] = {n1, n2, n3, n4, ...} for 0 to n - 1 total = total + array[n] print 'Average: ' print total / n end [/code] | |
Re: Plu-cha... before I go diving into analyzing 2d arrays and such, I want to see if maybe the following easy fixes help anything: -- Semi-colons. [code] while(roundNum<column) { cout<<"Enter Assembly numbers for round "<<roundNum+2<<endl; for (int x=0;x<row;x++) { cin>>assembly[x][roundNum]; } roundNum++; }; // you dont need me <--------------------------------- look [/code] … | |
Re: [code] i = test->info->returnCustomerID(); [/code] Did you ever declare 'i' ? | |
Re: [code] int recursiveGCD(int ,int ); int iterativeGCD(int ,int ); int input; [/code] The first two are fine (function prototypes). However the last line int input; when I was first reading I was thinking perhaps it was meant to be a function. If that was the original intention, then you would … | |
Re: I get lots of pretty output, (gcc compiler): >..-1208080203-1208080202-1208080201-1208080200-1208080199-1208080198-1208080197- >1208080196-1208080195-1208080194-1208080193-1208080192-1208080191-1208080190- >1208080189-1208080188-1208080187-1208080186-1208080185-1208080184-1208080183- >1208080182-1208080181-1208080180-1208080179-1208080178-1208080177-1208080176- >1208080175-1208080174-1208080173-1208080172-1208080171-1208080170-1208080169- >1208080168-1208080167-1208080166-1208080165-1208080164-1208080163-1208080162- >1208080161-1208080160-1208080159-1208080158-1208080157-1208080156-1208080155- >1208080154-1208080153-1208080152-1208080151-1208080150-1208080149-1208080148- >1208080147-1208080146-1208080145-1208080144-1208080143-1208080142-1208080141- >1208080140-1208080139-1208080138-1208080137-1208080136-1208080135-1208080134- >1208080133-1208080132-1208080131-1208080130-1208080129-1208080128-1208080127-...[/quote] #include<iostream.h> While it does not really matter if your compiler supports this, its usually a better idea to use the most recent header files #include <iostream> ... cout.fill('.'); for(i=i;i<10;++i) { cout.width(i); … | |
Re: A good way to go about it sometimes is to only consider the first error line. And then if you can't solve that look at the next line and see how that error might relate to the previous one. You need to understand the error messages; if you do not … | |
| |
Re: Heres some great links; [url]http://www.wikihow.com/Find-Motivation-to-do-Homework[/url] [url]http://www.macs.hw.ac.uk/~pjbk/pathways/cpp1/node42.html[/url] And a possible followup link: [url]http://www.mcdonalds.com/corp/career.html[/url] | |
Re: [code=C++] #include <iostream> using namespace std; bool Palindrome(string pal, int index, int length) { while(index < length) { if (length == 0 || length == 1) return true; if (pal[index] != pal[length - index]) return false; index++; } return true; } int main () { string word; cout << "Enter … | |
I read a post earlier about C++ books and whatnot. I have a few books from my yesteryears (10-13 years ago) on C++ mostly. How useful would these books be in terms of the language as it has progressed in the last 10 or so years. Are they even worth … | |
Re: Don't ever ever try to get cute with your code. Professors really seriously hate that. | |
Re: Check your braces. There are problems with them. | |
Re: I have a 10+ year old Accelerated C++ book covered in oil in the trunk of my car. Want it? :D | |
Re: [code]void circle() { double circleArea, rectangleArea, triangleArea, length, width, height, base, radius; char choice; const double PI = 3.14159; switch (choice) { case 'C': case 'c': case '1': [/code] You're making a switch and not giving "choice" a value. It's just getting garbage. I'm still reading through it, I'll edit … | |
Re: Running this code [code=C++] //============================================================================ // Name : mashley09_daniweb.cpp // Author : chococrack // Version : 1.0 //============================================================================ 1.) I have to enter #1 choice twice before it displays what number needing to translate. 2.) when i enter choice 2 it does not display the roman numerals for 1 through … | |
Re: cin >> name >> lastname; would work just fine too | |
Re: [code=C++] int 2dArray[4][5]; int x = 1; for(int i=0; i<4; i++) { for(int j=0; i<5; i++) { 2dArray[i][j] = x; x++; } } [/code] this sets up an array of 20 integers, 1-20 as follows [quote] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 … | |
Re: Well it's dead obvious... theres a SMILEY FACE IN YOUR CODE! o.0 | |
Re: [code] ifstream current_file; current_file.open(file.c_str()); // do stuff current_file.close(); [/code] Does that work? | |
Re: Everyone is perfectly safe, theres even webcams to watch: [url]http://www.cyriak.co.uk/lhc/lhc-webcams.html[/url] ;) |
The End.