No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
10 Posted Topics
it's classic traveling salesman problem using dynamic programming. the peseudocode is given : Inputs: a weighted, directed graph, and n, the number of vertices in the graph. The graph is represented by a two-dimensional array W, which has both its rows and columns indexed from 1 to n, where W … | |
Hi, I have one question. You know some applications can be minimized to the lower right corner and with a hot key (e.g. ctrl+F1). Once the hot key is pressed, the application is activated or some event is activated. I wonder how to do that in java if there is … ![]() | |
with java awt.Robot, I can have a sequence of mouse movements. However, I do not know what I should do to stop before it finishes. I was thinking a good way is to use a hotkey to interrupt. Can someone tell how to do that? More generall, how to set … | |
what is the easist way find out the number of lines in a txt file? there seems to be a function to ignore rest of the line...will that help? | |
i had a thought to write a program to play boggle. i already know how it works and decide to use a heap-based method. However, i just dont know how to write a basic step: look up a word in a dictionary. So,if i have a word "program", how can … | |
| |
i can use seekg and seekp functions to jump around differnt locations in the file with offset. But now the txt file is written like: 200200125,41123,John 200200125,31054,,David 200200125,45305,Nick 200200125,44866,Smith 200200125,41024,Cathy 200200127,31525,Steve 200200127,42429,Robert 200200127,42430.,Serena ... i wanna serch a lines with its second numer 44923 and get its first number. the … | |
>>i have defined a stack class using single linked list and a template. as follow: template <class T> class genStack{ public: void push(T a){.....} T pop(){........} .... .... private: SLList<T>: lst; } i know when i want the stack to store int, i should declare a stack like this: genStack<int> … | |
>>>is there any limit/constraint on the maximum number of nodes that a linked list can have? >>>a linked list does not have to be implmented with a pointer. what else can be implementeation of linked lists? >>>how can a singly linked list be implemented so that insertion requires no test … | |
How are an object’s data members initialized if a class has only an implicitly defined default constructor? And why a class might provide a "set" function and a "get" function for a data member? What is the purpose of the scope resolution operator? |
The End.