Posts
 
Reputation
Joined
Last Seen
Ranked #226
Strength to Increase Rep
+9
Strength to Decrease Rep
-2
93% Quality Score
Upvotes Received
14
Posts with Upvotes
14
Upvoting Members
11
Downvotes Received
1
Posts with Downvotes
1
Downvoting Members
1
10 Commented Posts
~76.2K People Reached
Favorite Tags

193 Posted Topics

Member Avatar for Alex Edwards

Writing a book is a good idea, but I'm not sure that writing a book on software engineering is the way to go for a thesis. Both Master's and Phd theses are much usually more focussed in a certain area of interest. Plus it also depends to some extent on …

Member Avatar for KelvinG
0
1K
Member Avatar for stilllearning

Hi, I looked for this information, but couldn't find it anywhere. Is there a difference between a "template class" and a "class template" or are they just two different ways of saying the same thing ? Thanks a lot.

Member Avatar for parchuresunilv
0
2K
Member Avatar for rrreeefff

Well you are printing "result" without initializing it or assigning it a value. Is result supposed to be your GCD ? Then you probably want to move your print to [B][I]after[/I][/B] you have computed your GCD and assigned it to the "result" variable. Did you intend to have your "if" …

Member Avatar for deceptikon
0
348
Member Avatar for em_jay

Well what you are doing will recursively delete all the nodes. If you want to delete only current leaves, then you need to do something like this. I haven't tested this, so please try it out. [code=cplusplus] void BinarySearchTree::removeleaf(tree_node* p){ if (p == NULL){ return; } else{ if (p->left || …

Member Avatar for shroog
0
1K
Member Avatar for nezhad

To access an element of the array "paths", you need to use the notation . not -> so its global_routing_info[neighbor].paths[no_paths].path_id = path;

Member Avatar for nataraja833
0
573
Member Avatar for shopnobhumi

First off, please use code tags, it makes your code easy to read. Now your loops [icode] while (i<4) { cout<<'*'; i++; }[/icode] This will print out "****" Your next loop [icode] while (j<5) { cout<<'*'; j++; cout<<endl; i++; } [/icode] will add a "*" to the first line, then …

Member Avatar for kavita_gunaji
0
811
Member Avatar for onemanclapping

for example on Linux you could compile using g++ -D_LINUX file.cpp -o output # turns on the #define _LINUX and on windows using g++ -D_WIN32 file.cpp -o output #turns on #define _WIN32 So if you had a makefile on both systems, you could set your compiler flags to reflect the …

Member Avatar for Ancient Dragon
0
2K
Member Avatar for basukinjal

You already have an example.. try to use that to work out an algorithm For eg: inorder is : 2 3 4 5 6 7 8 preorder is : 5 3 2 4 7 6 8 then the Binary tree shld be ________5 ________/\ _______3_7 _______/\_/\ ______2_4 6_8 Hint: 5 …

Member Avatar for xinhedanti
0
516
Member Avatar for stilllearning

I am really new to this, so please excuse me if this is a dumb question. I am saving some data using ruby on rails and one of those fields is a background for the divs I am rendering back on load. I created the partial layouts successfully but I …

Member Avatar for blocblue
0
115
Member Avatar for stilllearning

Hi, I have some code which creates an extremely long table row, and I've been able to clean it up to a point where my performance is fairly decent. What I am trying to figure out is if its better in terms of speed to use divs as opposed to …

Member Avatar for scrappedcola
0
108
Member Avatar for ishwarverma

You need to find out where the function BTRV is defined and then link to that library or object file.

Member Avatar for Member 784668
0
352
Member Avatar for SilentDuck

Your line[] array is local to each function, so your values really won't transfer between the two functions. Do you know how to pass arguments to functions ? If so then pass in a reference to your array as the argument for each function.

Member Avatar for Banfa
0
211
Member Avatar for Kombat

Check out this link [url]http://www.cs.rpi.edu/academics/courses/spring06/cs2/resources.html[/url]

Member Avatar for WaltP
0
81
Member Avatar for tones1986

Ok, I think this is roughly what you are looking for. You will still need to fine tune it to get the final answers you need. Some parts are hard coded, like assuming your associate id's range from 21 - 26. You might want to read those values in if …

Member Avatar for bobydavid71
0
210
Member Avatar for Eko

You could also initialize a float using float a = 0.1f; The f tells the compiler that its a float.

Member Avatar for dwayneb
0
5K
Member Avatar for preet4fun

Regarding the -25.00 .. I guess it would mean that the customer owes the bank 25 dollars as a service fee for letting the balance drop below their minimum balance .. You might want to throw a warning message if the customer enters a balance which is less than the …

Member Avatar for puranchandra248
0
2K
Member Avatar for tundra010

In your linker settings have you typed in the complete path to where fltk.lib is located ? By default it'll look for it in the current project directory. If fltk.lib is something you are supposed to compile also, then make sure that project is added as a dependency for your …

Member Avatar for tundra010
0
274
Member Avatar for Chumpcash
Member Avatar for wislean

I would clean up the printf a bit by making it more readable. Also I am not sure why you are passing the argument "&menu" to your printf. Its incorrect in this context. Something like this would be much easier to read. [code]printf("1.Print list of students\n"); printf("3.Print list of those …

Member Avatar for csurfer
0
164
Member Avatar for VMG

Are you positive you have the shared library wld.so in your /home/vincenzo/software/borealis-projects/LoadDistributionTool ? And what is this supposed to be ? ${BOREALIS}/nmstl/bin/wtf ? its not preceded by a libtool option.

Member Avatar for acastella
0
112
Member Avatar for DemonGal711

I don't think just L and R will cut it. Lets say your maze is a rectangle that has n number of points, and there are walls inside it that construct a number of paths. Now the user needs to take the path that will take him/her to the finish. …

Member Avatar for stilllearning
0
130
Member Avatar for Niner710

I think what is happening is this [icode] Tblk A; Tblk B = A; [/icode] This is using a default copy constructor since you haven't defined one, and both your objects A and B are pointing to the same set of strings. So when you leave main, both A and …

Member Avatar for skatamatic
0
171
Member Avatar for rrlangly

I am a little confused by your queue implementation. Usually your queue functions would be enqueue to add the elements to the queue, and dequeue to get the first element you added off the queue, simulating FIFO behavior. A stack on the other hand uses push and pop for LIFO …

Member Avatar for stilllearning
0
155
Member Avatar for tefismp

Here is a tutorial on bucket or bin sort. [URL="http://en.wikipedia.org/wiki/Bucket_sort"]Link[/URL] Each array of yours will be a bucket. You can create as many arrays as the buckets you'll need. Then sort each array (bucket). And finally merge all the sorted arrays (buckets). Its pretty simple. The main thing is figuring …

Member Avatar for Freaky_Chris
0
164
Member Avatar for christiangirl

First of all, its good practice is to put your class declarations in a header or a .h file, put your definitions in a .cpp file and then include the .h file, where needed. You really should not be including your .cpp files in other files. The rest, coming in …

Member Avatar for Freaky_Chris
0
244
Member Avatar for koman

I am curious .. how did you get this to compile ? [icode] if ( ( i == 2 ) or ( i % 2 != 0 ) ) [/icode] There is no keyword called "or" in C++ its denoted by "||"

Member Avatar for stilllearning
0
165
Member Avatar for RonaldvanMeer

Well your variables below are local to the function. So when you leave the function, they don't exist and so their addresses now probably point to garbage values. You should copy the values over onto your start pointers array, instead of pointing it to an address of a local variable. …

Member Avatar for RonaldvanMeer
0
165
Member Avatar for Avaviel

One thing, which may or may not be a problem, is this [icode] if (validAccount == false) { ..... switch(AccountType) { case 's': case 'S': .... validAccount = true; ... } } else cout << "You entered the wrong account type. Please check input file."; [/icode] Now the first time …

Member Avatar for Avaviel
0
343
Member Avatar for msundastud

A void function would generally look like this [icode] void foo(){ return; } [/icode] But trying to do this is wrong. [icode] void foo(){ int retvalue; return retvalue; }; [/icode] Moral, you cannot return values from a void function. Its incorrect, and a good compiler should throw an error if …

Member Avatar for devnar
0
164
Member Avatar for ambarisha.kn

Pass them in as pointers from your calling function. [icode] void fbExeCode(int BldCnt, char* fCodeAddr, char* tmpAddr){ } [/icode] A few things to be careful about. If you want to allocate them in fbExeCode, then initialize them to NULL to be safe. Also make sure you don't lose the starting …

Member Avatar for Ancient Dragon
0
146
Member Avatar for NinjaLink

You aren't assigning the variable index a value before calling the functions removeAt and insertAt. So you need to fix that first. Well I just noticed that you are asking for the index in your function, in which case why are you passing "index" to it ? You really shouldn't …

Member Avatar for NinjaLink
0
131
Member Avatar for DemonGal711

Are you familiar with vectors ? If so you can use a 2 dimensional vector and that way you wouldn't have to mess with the memory allocation yourself. [URL="http://www.daniweb.com/forums/post709079.html#post709079"]here[/URL] is an example of how you can allocate and use a 2 dimensional array with pointers.

Member Avatar for DemonGal711
0
122
Member Avatar for oceanicblack

You need to make an effort to write something .. you cannot honestly expect someone to solve your midterm exam for you.

Member Avatar for stilllearning
0
229
Member Avatar for mathrules

Here is a link that mentions how the fstream getline works [URL="http://www.cplusplus.com/reference/iostream/istream/getline.html"]Link[/URL] What you need to do is [icode] SortedBinary.getline(myBuffer, mySize," "); [/icode] where myBuffer is a string where you store the word you are reading from the file, and mySize is the maximum size you can store.

Member Avatar for sidatra79
0
196
Member Avatar for sladesan

Well I see in your main() function [icode] scout *p; [/icode] and then [icode] p[s].ips = bohica; p[s].startport = start; p[s].endport = end; [/icode] But I don't see you allocating memory for p anywhere ? You need to to do that.

Member Avatar for stilllearning
0
169
Member Avatar for alin_yuhee

Add Code Tags Please !!! And there is no [icode] #include<iostream.h> [/icode] its [icode] #include<iostream> [/icode]

Member Avatar for alin_yuhee
0
116
Member Avatar for lanilonzo

lol .. contrary to popular belief, we are not clairvoyant, so you need to elaborate on what you are doing , what your problem is and post some code you've worked on !!

Member Avatar for stilllearning
0
71
Member Avatar for jkun2

You should be able to print the output to your file, from your inorder() function, if that is the order you want it in. You can open the output file in your BinarySearchTree::print_inorder() and then pass the root node and the file pointer to your inorder() function. And fyi this …

Member Avatar for stilllearning
1
1K
Member Avatar for JimD C++ Newb

At first glance, your traverse function is declared as a void, yet you are doing [icode] result = tree.traverse(INFIX, printData(data)); [/icode] This is not valid. I don't know what result is, but if its a boolean, then you need to accordingly fix the definition of your traverse function. Also if …

Member Avatar for chococrack
0
128
Member Avatar for killdude69

um .. could it be a spelling mistake on your part ? its __declspec( dllimport ) not __declspec( dllimort )

Member Avatar for Ancient Dragon
0
152
Member Avatar for Se7Olutionyg

Is this your complete code ? Because I don't see any ending braces for your do_next_op function. Also what errors do you get, elaborate !!

Member Avatar for unbeatable0
0
90
Member Avatar for tatainti55

bool is the boolean datatype. A variable declared as a bool can have 2 values true (= 1) or false (= 0). [URL="http://www.functionx.com/cpp/keywords/bool.htm"]Here[/URL] is an explanation with an example.

Member Avatar for tatainti55
0
97
Member Avatar for teddybouch

Well I tried putting your stuff in a standalone program and it works without any difficulties. It is possible that you have code elsewhere which is corrupting your stack, and the problem shows up when you call timeGetDevCaps. Have you considered running your code through a memory checking tool ?

Member Avatar for Salem
0
103
Member Avatar for cerb63

Did you want to try and do a non-recursive factorial or a non-recursive way to compute the fibonacci ? Please put tags around your code. And for a non-recursive fibonacci. You could do something like this [code] int fib(int n){ int previous = -1; int result = 1; int sum; …

Member Avatar for Salem
0
216
Member Avatar for Nasi23

Add code tags to around your code. And what kind of errors are you getting ? You need to elaborate.

Member Avatar for stilllearning
0
192
Member Avatar for n8thatsme

Well you can define a variable of type "string" and then use += to add the words to it for example: [icode] string myString; for (int i =0; i < maxwords; i++){ myString += randomwords[]; myString += " "; } [/icode]

Member Avatar for n8thatsme
0
169
Member Avatar for denner

This would be so much easier to parse out using scripting :). If you are going to parse the output of ls -al, keep in mind that your permissions, are for the root, the group and the user. And the preceeding "d" indicates whether that is a directory or not. …

Member Avatar for stilllearning
0
674
Member Avatar for afg_91320

You need to fix your main function. You are not passing in the correct arguments ! [code] int main() { int User; int Computer; int choice; char answer = 'y'; while (answer == 'y' || answer == 'Y') { User = UserChoice(); Computer = ComputerChoice(); choice = DetermineAndDisplayWinner(User,Computer); PrintObject(choice); cout …

Member Avatar for chococrack
0
131
Member Avatar for mypopope

You need to post the link errors you are getting from the compiler so that we can help you.

Member Avatar for stilllearning
0
120
Member Avatar for rkumaram

To add to the discussion, here is a bit more about Operator Overloading. For example lets take a part of an ArrayClass where you overload the operator [] for objects of this [B][I]class[/I][/B] [code] class Array{ ---- public: int& operator[](int); /* pass in subscript */ ---- private: int ArraySize; int* …

Member Avatar for ArkM
0
151

The End.