Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
51% Quality Score
Upvotes Received
21
Posts with Upvotes
19
Upvoting Members
18
Downvotes Received
24
Posts with Downvotes
18
Downvoting Members
15
7 Commented Posts
~102.11K People Reached
Interests
Video games, coding, football,adventures
PC Specs
Windows 7 (x86)
Favorite Tags

195 Posted Topics

Member Avatar for Gotoma

If I were you, I'd avoid using char arrays ... what happened to string? [CODE] //Employee.h // // #include<iostream> #include<string> using namespace std; class Employee { private: string name,lastname; // String of name and last name; int salary; public: Employee() // Constructor to initialize default values. { salary=0; name=""; lastname=""; …

Member Avatar for aashi.bajwa.9
0
10K
Member Avatar for Shinedevil

Nice,long code..cool ideas...not so good organisation...doesn't compile on nearly all compilers apart 4rm dev-c++(i tried to compile it on borland c++.8 errors). all in all, good code

Member Avatar for mrpi64
0
2K
Member Avatar for tkud

Hi,everyone.. I was wondering.. Is it possible to carry out other tasks in a php application while data is being uploaded(by that application) into a MySQL database?

Member Avatar for tkud
0
214
Member Avatar for yuugib

[CODE] 14.cout << "Please enter the values:\n"; 15.cin >> nums[size]; [/CODE] The above lines would only accept 1 value....nums[size]. Use a loop instead: [CODE] for(int i=0;i<size;i++){ cin>>nums[i]; } [/CODE]

Member Avatar for meggy12
0
332
Member Avatar for robinotje

you could use cstdlib's [B]system()[/B], then call DOS function rmdir.. [CODE] string name = /* The directory path */; system("rmdir /s /q " + name"); [/CODE]

Member Avatar for Ancient Dragon
0
15K
Member Avatar for blaisemcrowly

You can try this: [Developing a Media Player using C++](http://msdn.microsoft.com/en-us/library/windows/apps/xaml/hh986967.aspx)

Member Avatar for rubberman
0
1K
Member Avatar for cutterpillow20
Member Avatar for grh1107
0
819
Member Avatar for capton

[QUOTE]Please i want to end a program in a function outside function main.[/QUOTE] All functions run in [B]main()[/B], since it's the entry point of the program. No user-defined function can run outside [B]main()[/B]. Once [B]main()[/B] ends, all other functions end.

Member Avatar for AceStryker
0
2K
Member Avatar for Labdabeta

(1) Are you asking for advice concerning the AlphaBeta algorithm or (2)have you written code and you need help to progress further? If (2), post the code you have written so far(using code tags, of course).. If (1), get a good C++ book.

Member Avatar for Labdabeta
0
169
Member Avatar for gopal1993
Member Avatar for vyrte

[URL="http://www.cplusplus.com/reference/iostream/istream/seekg"]This will help.[/URL]

Member Avatar for WaltP
0
167
Member Avatar for Srinivas0

[CODE] #include <iostream> using namespace std; class LoopEx { public: int x ,y; void Ex(){ x = 1; // Point 1 y=3; while(y>0){//Point 2 x=x*y; --y; } cout<<x; } }; int main() { LoopEx F; F.Ex(); return 0; } [/CODE] Point 1 : If you initialize x to zero, any …

Member Avatar for Srinivas0
0
108
Member Avatar for Desh2350

[CODE] double Rational::division(Rational c) { numerator = numerator * c.denominator; // divides numerator and denominator denominator = denominator * c.numerator; // divdes denominator and numerator return reduction(); } [/CODE] You are multiplying here instead of dividing..

Member Avatar for Schol-R-LEA
0
4K
Member Avatar for smata

[QUOTE] can you help?. i know some coding [/QUOTE] Show us what you know... We'll help you from there..

Member Avatar for tkud
0
189
Member Avatar for duttydane
Member Avatar for Interista

Your code has a lot of errors.. [QUOTE] Menu soccerClothesMenu("soccer"); [/QUOTE] The Menu struct does not have a constructor that takes a string as a parameter. Rather, the only constructor int the struct: [CODE] Menu(const std::string& name, const std::vector<Menu> subMenus): name(name), subMenus(subMenus){} [/CODE] takes two parameters. [QUOTE] int main(){ { …

Member Avatar for Interista
0
130
Member Avatar for ZeroEddy

This is funny.. How can you claim to have studied Java for a year and you don't know how to create objects and classes? Nobody would believe that.

Member Avatar for ZeroEddy
0
239
Member Avatar for loserspearl

[CODE] try { guess = Integer.parseInt(guessStr); //tells the use to enter a valid integer if (guess < 0 || guess > 10) message = "Enter a number between 1 and 10."; guessStr = JOptionPane.showInputDialog(null, message, chanceStr, JOptionPane.ERROR_MESSAGE); } catch (Exception ex) { [/CODE] Try [B]catch[/B]ing an [B]InputMismatchException[/B] instead of an …

Member Avatar for adarshcu
0
216
Member Avatar for Zssffssz

[QUOTE]Ok the thing I searched into google brought up a ton of nonsense. I want to use variables from a function in main and (more important) variables from main in a function.[/QUOTE] Declare the variables globally.i.e before main() [CODE] #include<iostream> using namespace std; //declare variables here int main(){} [/CODE]

Member Avatar for gerard4143
0
170
Member Avatar for TheComputerGuy

Remove the [B]abstract[/B] keyword or you can make [B]SquareBaseContainer[/B] an interface. By the way, [B]SquareBaseContainer[/B] extends [B]BaseContainer[/B], which is also [B]abstract[/B]. Remove the [B]abstract[/B] keyword from there, too.

Member Avatar for TheComputerGuy
0
135
Member Avatar for Santosh gupta
Member Avatar for tkud
0
71
Member Avatar for meli123

for(loop the following code n times){ pow = pow multiplied by m } So if we are to loop 'pow * 3' 2 times, that would be: pow = 1 * 3 = 3 pow = 3 * 3 = 9

Member Avatar for tkud
0
106
Member Avatar for ziyadgodil
Member Avatar for jh3lps

Where's the definition of Update_records() and TimeStep()? and where did you declare NO_OF_PLANTS and plants[]? Please post the full code.

Member Avatar for raptr_dflo
0
783
Member Avatar for Johnny666

[URL="http://www.learncpp.com/cpp-tutorial/912-shallow-vs-deep-copying/"]This [/URL] should help in your understanding of shallow and deep copying.

Member Avatar for raptr_dflo
0
184
Member Avatar for logan_231_2009

[CODE] #ifndef personH #define personH class Person { private: //Try making height_ and weight_ protected instead of private static float height_; static int weight_; public: void setHeight(float height); void setWeight(int weight); static float getHeight(); static int getWeight(); }; //--------------------------------------------------------------------------- #endif [/CODE]

Member Avatar for raptr_dflo
0
113
Member Avatar for Hayzam Sherif

Can you write assembly programs? if yes, then you should probably read [URL="http://en.wikipedia.org/wiki/Booting#Boot_loader"] this.[/URL] Your understanding of computer architecture will be of help to you, too.

Member Avatar for Hayzam Sherif
0
180
Member Avatar for srednakun

You need to also overload the other operators you used in the above code. if you have, post the code.

Member Avatar for tkud
0
155
Member Avatar for v1nc3nts

Most of your errors are due to incorrect usage of the "extern" keyword.[URL="http://msdn.microsoft.com/en-us/library/0603949d%28v=vs.80%29.aspx"] This[/URL] should help.

Member Avatar for Ketsuekiame
0
326
Member Avatar for tiredoy

A base class, as the name suggests, acts as a 'base' for derived classes. Example: class Car has 3 derived classes, Toyota,Honda and Chevrolet. Functions and variables you want to use in Toyota but not in Honda can be in Car. Also, methods and variables that you want in all …

Member Avatar for mike_2000_17
0
232
Member Avatar for mark_6

[QUOTE]The program forms the letter [B]Z[/B] by printing n input character symbols on the upper line, n input character symbols on the lower line, and n input character symbols on the diagonal line.[/QUOTE] However, down the line, your output shows the drawing for [B]C[/B], not Z... I don't get your …

Member Avatar for sumant mahadik
-1
1K
Member Avatar for fsefsef23

[QUOTE]The 'idea' behind my loop is that it was supposed to read the player's information and record it up to the number of 'atBats', then count the hits, etc. of that player based on the number of atBats (via the second loop), record that, then start over again but for …

Member Avatar for fsefsef23
0
250
Member Avatar for Celtrix

If your machine is too slow to run windows or mac, you shouldn't be telling people to post what they do on a daily basis, cos it mostly involves Windows or Mac! you should be thinking of changing your machine....

Member Avatar for Celtrix
0
110
Member Avatar for FoxInBoots

It seems your sort function is in ascending order, so this should do: [CODE] string test[] = {("Testing sorting strings"), ("Pray this works")}; int array_size = sizeof(test) / sizeof(test[0]);//To find the number of elements in the array for(int i = 0; i<array_size;i++){ if(test[i][0] > test[i+1][0]){ cout<<test[i]<<endl; } else { cout<<test[i+1]<<endl; …

Member Avatar for NathanOliver
0
126
Member Avatar for iamthwee
Member Avatar for pril

[QUOTE] It's not possible to determine if the array is empty or not without knowing the array size. Even then the only way to tell if the array is empty is if the array size is 0. [/QUOTE] You assign the array size to an int variable, then return "true" …

Member Avatar for pseudorandom21
0
114
Member Avatar for shilosimi

The problem might not be from the code fragment posted here. Post your full working code.

Member Avatar for tkud
0
169
Member Avatar for gregarion
Member Avatar for raj03

[CODE]34. if (mark 0<a<50);[/CODE] 'mark' is nt supposed to be there, or were u trying to write 'mark<0<a<50'?

Member Avatar for tkud
0
192
Member Avatar for iamuser_2007

Now, Where's your code? Haven't you tried solving this problem yourself? Post your progress if you've attempted this.. Else, have a go @ it, then come back if u have any problems....

Member Avatar for sergent
-2
192
Member Avatar for sim08u
Member Avatar for jory

Read up on the functions and capabilites of C++ Strings.. That would do you a lot of good..

Member Avatar for predator78
-1
105
Member Avatar for yashsaxena

Encapsulation is wrapping data into single unit (e.g A class) Abstraction is hiding unessential parts and showing only essential data.

Member Avatar for yashsaxena
0
4K
Member Avatar for Bulls2012
Member Avatar for ragedsparrow
0
376
Member Avatar for 123priya

That's because ur function prototypes ARE in main()... And try using int main() instead of void()...

Member Avatar for tkud
0
94
Member Avatar for programing

Writing a compiler?? That defines just 4 basic math operators??? A compiler??!!

Member Avatar for template<>
0
124
Member Avatar for Jimmyteoh
Member Avatar for Jimmyteoh

Jimmyteoh, U were told to post your code for ur question, not repeat it in another person's post...

Member Avatar for peter_budo
-3
125
Member Avatar for narunaru
Member Avatar for andimiami

[CODE] #include<iostream> using namespace std; string parseInputString (string oneline) { string newName; string firstName, lastName; int index; index = oneline.find(' '); int ret = oneline.at(index); firstName = oneline.substr(0, index); oneline = oneline.substr(index + 1, oneline.length() - 1); lastName = oneline; newName = lastName + ", " + firstName + "."; …

Member Avatar for andimiami
0
122

The End.