447 Posted Topics

Member Avatar for zandiago

One thing you could do is map out a directory. The structure could have the name of the directory, an array of sub-directories (which would possibly be a pointer to a new instance of the structure itself), and an array of file names as members. You can search through it …

Member Avatar for zandiago
0
560
Member Avatar for The Dude

The pee from a cat reeks more than that of a dog, in my experience. My father throws things at cats who go into our garden!

Member Avatar for bobbyraw
0
107
Member Avatar for The Dude
Member Avatar for The Dude
Member Avatar for sneekula
0
115
Member Avatar for The Dude

Jaz Hands *scuttles off stage in a diagonal direction* Some predictable ones, of course, but some good ones too. Jazz is great. I saw a great Jazz guitarest during the summer ... I can't remember the name of him for the life of me ... But if ye ever hear …

Member Avatar for sneekula
1
138
Member Avatar for hollystyles
Member Avatar for The Dude

I got up to about 16 the other week. I'm 21. I was using some ultrasonic transducers I'm doing work on. It's weird. They're meant to have a narrow bandwidth at about 40 khz with 20dB/dec either way around the peak but you could hear well enough up to your …

Member Avatar for bumsfeld
0
483
Member Avatar for bumsfeld

>> In Britain a pregnant woman can legally relieve herself into a policeman's helmet. I believe it's actually anywhere. But I'm not quite certain. It's been a while since I got that email ...

Member Avatar for Lardmeister
0
245
Member Avatar for ithelp

>> Good time to go to the pub with friends! Yeah. Cause in Ireland we don't actually work :) Pubs 24/7, heh.

Member Avatar for bumsfeld
0
98
Member Avatar for jasimp

Never timed myself. Don't know any of these systems though. Just did it imprompto. You know they can all be solved in less than 26 moves or something! [url]http://www.guardian.co.uk/science/2007/aug/17/2?gusrc=rss&feed=networkfront[/url]

Member Avatar for Sturm
0
122
Member Avatar for twomers

I'm sure some of you guys have this already, but I downloaded this the other day and it's made my life (pretty much), so I thought I'd share. It's an addon for FireFox which blocks those annoying adds you see all over the place. Deffo worth the download, IMO. [url]https://addons.mozilla.org/en-US/firefox/addon/1865[/url]

Member Avatar for jwenting
0
113
Member Avatar for dantheman3141

Got any computer screens you don't need? Or microwaves? Find a high wall and push.

Member Avatar for MidiMagic
3
115
Member Avatar for cl3m0ns

You want a user to enter the number of employees and an array with that number of elements? That should be easy enough. There are a number of options. You could use traditional dynamic memory allocation or alternatively a container class like vector. I'm going to assume you've not learnt …

Member Avatar for cl3m0ns
0
98
Member Avatar for cl3m0ns

It should be protected rather than public. The Employee members. That's all I can guess here. If that doesn't work post some code. Pour example: [code=cpp]class thing { private: int priv_int; protected: int prot_int }; class inh_thing : public thing { public: void display( void ) { // std::cout<< priv_int …

Member Avatar for twomers
0
332
Member Avatar for joshua.tilson

For the second question you could use \r in a print statement. This goes to the start of the line on the console window. So suppose I had this: std::cout << "hello, \rworld"; I would get out: "world, " Least I think it's \r Only danger with it though is …

Member Avatar for Duoas
0
343
Member Avatar for ace_joker_bt

I really don't know what you mean, but you might want to open the files in binary mode...

Member Avatar for ace_joker_bt
0
355
Member Avatar for RichardNero

You're right. Why bother using code tags. >> int main(); >> { Should be >> int main() >> { No ; after main.

Member Avatar for Salem
0
108
Member Avatar for Justmehere

If all you want to do is wait for a while you can use sleep...: [code=cpp]#include <windows.h> int main() { // Do something Sleep( 1000 ); // Sleep( miliseconds ); // Do more somethings return 0; }[/code]You can put the sleep in an infinite loop if you want it to …

Member Avatar for Justmehere
0
197
Member Avatar for Lardmeister

Well ... our 'prime minister' just passed a vote of no confidence from the opposition ... There are issues with money that appeared in his account too ... so I guess he has a sense of humour ... :)

Member Avatar for Lardmeister
0
531
Member Avatar for joshSCH

I couldn't see it kicking off. The sports which are popular here have had a long time to sink their talons into the hearts of their fans. American football... may be a passing fad but no more than that, in my opinion.

Member Avatar for bumsfeld
0
213
Member Avatar for twomers

Hi all. In university we're studying different types of power systems and generation methods and one of the more interesting types are nuclear stations. I know where I stand on it but I'm curious as to what others think. For, or against? Please specify why.

Member Avatar for bumsfeld
0
736
Member Avatar for Lardmeister
Member Avatar for The Dude
Member Avatar for sirkraven

Don't forget that you need a ; at the end of your class defn - [code=cpp]class class_name { // ... };[/code] In C when you created a struct and didn't define it with a typedef you'd have to say: struct struct_name struct_instance_name; rather than what you'd be used to. However …

Member Avatar for twomers
0
102
Member Avatar for The Dude

So I haven't read this, but there's no mystery to the situation - [url]http://twomers.googlepages.com/ne.PNG[/url]

Member Avatar for twomers
0
177
Member Avatar for mannantes

Do you know how to use file streams in C++? Just create a file, it doesn't matter what you call it, for writing (ofstream), and then create another stream for reading (ifstream). Use the getline function on the input file stream ([inlinecode]while( std::getline(in, line) )[/inlinecode]), where line is a std::string), …

Member Avatar for mannantes
0
4K
Member Avatar for joshmo

Wow. We give out about people not giving us enough code all the time ... but [I]all[/I] the code... one would think it's a good thing... However, I, for one, am not going to look at any of them. I think it's generally said to post the smallest segment of …

Member Avatar for joshmo
0
81
Member Avatar for pdwivedi

Simple file io. First hit on google - [url]http://www.cprogramming.com/tutorial/cfileio.html[/url]. All you need to do is point the file pointer to your desktop. You can hard code that if you want. Then open the file for reading (see link), and print its contents to screen.

Member Avatar for WaltP
0
124
Member Avatar for rugae

I really don't think it'll affect your either way. I mean. It's 15 const ints...

Member Avatar for vijayan121
0
130
Member Avatar for Dave Sinkula

I decided to go out in the last minute so I grabbed a cane, a pill box, some tictacs and hey presto I was Dr. House. A buddy of mine went as Predator and another as Awesomeo. Both were excellent but both made it awkward to drink anything!

Member Avatar for twomers
0
128
Member Avatar for Dave Sinkula

Yeah. I've always (not really), wanted to try vicodin since I started watching House. Not that I'm impressionable or anything...

Member Avatar for scru
3
778
Member Avatar for Dave Sinkula
Member Avatar for MidiMagic
0
103
Member Avatar for MidiMagic

There's a lot of talk about drugs here of late (kinda). Did anyone ever play this game - [url]http://www.geekhideout.com/druglord2.shtml[/url] It's pretty amusing!!

Member Avatar for Ezzaral
0
388
Member Avatar for The Dude
Member Avatar for hbk619
0
47
Member Avatar for donaldunca

Create a string containing all the letters you want to use. Seed and use rand() to access elements (using the % operator to force the numbers within the string's range). Strcat in a loop. Pseudo-code. [code=c]my_letters = "abcdefghijklmnopqrstuvwxyz" /* allowable letters for your random string */ my_random_string /* your random …

Member Avatar for donaldunca
0
162
Member Avatar for lasher511

How are we meant to defend ourselves for the impending alien attacks if we don't enhance ourselves? Thankfully colonies from the future have send back in time 'videos' and 'movies' to train us in such matters.

Member Avatar for Dave Sinkula
0
130
Member Avatar for DREAMER546
Member Avatar for ecestd1

Erm. Copy all relivant data? By the looks of it start at the back pointer and iterate to the front pointer assigning the values at each of the nodes (from Q), to your object along the way.

Member Avatar for ecestd1
0
1K
Member Avatar for navy2005

[QUOTE]cout << "Enter the grade for Exam 1: "; cin >> 100 //...[/QUOTE] I assume what you want is to have those as the inputs, right? That doesn't work. You can't read in a number like that. What you're going to have to do is read in [I]a variable[/I] and …

Member Avatar for navy2005
0
275
Member Avatar for cmoodc

I'm sure wikipedia will have something of another on the subject - [url]http://en.wikipedia.org/wiki/Hyperbola[/url]

Member Avatar for twomers
0
118
Member Avatar for sicon99
Member Avatar for twomers
0
124
Member Avatar for sicon99

[B]Calvin:[/B] Dad, how do cash machines work? [B]Calvin's Dad:[/B] There's a small man behind the machine and when you say how much you want he posts it out the hole. [B]Calvin:[/B] Oh! Just like the man who opens the garage door? [B]Calvin's Dad:[/B] Exactly It's like that for most automatic …

Member Avatar for MidiMagic
0
125
Member Avatar for AnthIste

You can point it to the first y position. int *p = numbers[0]; Or whichever one you want.

Member Avatar for AnthIste
0
116
Member Avatar for The Dude
Member Avatar for Lardmeister
0
41
Member Avatar for blindkilla

Well. Regardless of the loop kind (assuming it's allowed to iterate enough times), it should read in the info: [code]while ( in >> word ) std::cout<< word;[/code] Where in is your input file stream and word is something used to store the information of the file.

Member Avatar for WaltP
0
118
Member Avatar for Serunson

I recommend celebration! What are you doing here? Happy birthday, though. Now you have no excuses to not be unsensable. :)

Member Avatar for Serunson
1
204
Member Avatar for warpstar

It's a 2-D array, presumably. Start from the top and go along each row and record the position of the first one. Pseudo code: [code]loop y=0, 5 loop x=0, 5 if val of array[y][x] is 1 print (x+1) break loop end loop x end loop y[/code]

Member Avatar for warpstar
0
90
Member Avatar for cl3m0ns

Dude, I told you to use code tags! One option would be to read the value to a temp string. Test that for "stop". If it is stop assign the new element that value. Else break. Then outside of the loop test that string for "stop" and do what you …

Member Avatar for cl3m0ns
0
126
Member Avatar for cl3m0ns

So the problem is in sorting the arrays? Look into this - [URL]http://www.cplusplus.com/reference/algorithm/sort.html[/URL] It's the standard sorting method. The example there is numerical but I'm certain it does alphabetical data too. >> if there are less then 20 clients being entered i would like to be able to stop the …

Member Avatar for twomers
0
145
Member Avatar for Lardmeister

The End.