Search Results

Showing results 1 to 25 of 25
Search took 0.10 seconds.
Search: Posts Made By: winbatch
Forum: C++ Mar 3rd, 2006
Replies: 5
Views: 1,536
Posted By winbatch
You're treating deck[i] like a pointer when it's not.
Forum: C++ Feb 8th, 2006
Replies: 4
Views: 6,029
Posted By winbatch
#include <iostream>
#include <sstream>
using namespace std;
int main()
{
int a =23545;
ostringstream o;
o<<a;
cout<<o.str().size()<<endl;
return 0;
Forum: C++ Jan 26th, 2006
Replies: 13
Views: 5,651
Posted By winbatch
http://www.delorie.com/djgpp/v2faq/faq22_25.html
Forum: C++ Jan 25th, 2006
Replies: 13
Views: 5,651
Posted By winbatch
Also, main really should return an int.
Forum: C++ Jan 21st, 2006
Replies: 4
Views: 1,707
Posted By winbatch
trade(word[i]) != '\n' || i < 5)

(don't you want && i< 5 )
Forum: C++ Jan 17th, 2006
Replies: 5
Views: 1,233
Posted By winbatch
add a 'using namespace std' at the top and see if it makes a difference.
Forum: C++ Dec 18th, 2005
Replies: 13
Views: 15,963
Posted By winbatch
http://www.daniweb.com/techtalkforums/showthread.php?t=36339
Forum: C++ Dec 17th, 2005
Replies: 7
Views: 1,655
Posted By winbatch
You don't need pointers here at all to begin with, if you are predetermining your maximum number of doctors at 5. (Also, if you are asking for 5 doctors, why are you only looping from 0 to 2? You...
Forum: C++ Dec 16th, 2005
Replies: 7
Views: 1,655
Posted By winbatch
Also, anything you create with 'new' needs to be 'deleted'
Forum: C++ Dec 13th, 2005
Replies: 11
Views: 1,855
Posted By winbatch
Sorry, displayMenu.h and menu.h
Forum: C++ Dec 12th, 2005
Replies: 11
Views: 1,855
Posted By winbatch
This wouldn't surprise me either as for example you have more than one .h file with the same function:
int main_menu() ( in menu.h and displayMenu.h)
Forum: C++ Dec 11th, 2005
Replies: 3
Views: 4,494
Posted By winbatch
Check that you aren't missing a } or have 2 }} when you should only have 1. I've had silly errors like that give me hundreds of compiler errors..
Forum: C Dec 4th, 2005
Replies: 5
Views: 1,884
Posted By winbatch
Does your filename or path contain a space? If so, make sure to pass it inside double quotes...
Forum: C++ Dec 4th, 2005
Replies: 4
Views: 1,734
Posted By winbatch
Tim,

As I mentioned in my email, you've got to make this question a lot clearer....
Forum: C++ Dec 3rd, 2005
Replies: 2
Views: 2,864
Posted By winbatch
http://www.cprogramming.com/tips/showTip.php?tip=42&count=30&page=0
Forum: C++ Aug 15th, 2005
Replies: 4
Views: 4,690
Posted By winbatch
Not sure about linux, but on solaris, you need to update your LD_LIBRARY_PATH environment variable to include the directory with the shared objects you want to load... (and on AIX, it's LIBPATH)......
Forum: C++ Jul 17th, 2005
Replies: 13
Views: 86,689
Posted By winbatch
I know what you mean...

By the way, no need to quote the entire previous posting when putting a reply (only the relevant piece)..
Forum: C++ Jul 16th, 2005
Replies: 13
Views: 86,689
Posted By winbatch
So Picky ;). As you wish:

#include <iostream>
using namespace std;
void prime_num(int);
int main()
{
cout << " Enter a number and I will generate the prime numbers up to that number: ";
int...
Forum: C++ Jul 16th, 2005
Replies: 13
Views: 86,689
Posted By winbatch
Here's what I went with. Note you want to do a break if you find out it's divisible as there is no point in checking all the numbers beyond it for divisibility..


#include <iostream>
using...
Forum: C++ Jul 9th, 2005
Replies: 14
Views: 2,338
Posted By winbatch
Did you copy and paste what dave wrote and compiled it?
Forum: C Jun 8th, 2005
Replies: 12
Views: 47,941
Posted By winbatch
you can do this:

char temp[10];
int num = 3;
sprintf( temp, "String%d", num);
Forum: C Jun 8th, 2005
Replies: 12
Views: 47,941
Posted By winbatch
gebbit, you can also look into sprintf, which gives you a lot of options.
Forum: C Jun 7th, 2005
Replies: 9
Views: 60,669
Posted By winbatch
OK, but why the for loop? You only want the user input once correct?
Forum: C Jun 7th, 2005
Replies: 9
Views: 60,669
Posted By winbatch
A couple of things:

First, you need to include "stdlib.h" for atoi. (Note, I think atoi is not standard, consider sprintf)

Second, you are trying to get the length of an integer (...
Forum: C++ May 23rd, 2005
Replies: 2
Views: 1,446
Posted By winbatch
I don't see the need for "\n" on this line...

cin >>typed_choice>> "\n";
Showing results 1 to 25 of 25

 


About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC