659 Topics

Member Avatar for
Member Avatar for scoob

I have this assignemt to make a double link list for a student database. I have tried to make it in single link list so that i can understand the implementation. the problem is that i can't make it a double link list :S i am so confused! plz someone …

Member Avatar for scoob
0
252
Member Avatar for thegecho

I've been working on this for a couple days and know it's something small but for the life of me I can't figure it out. (I've been using Daniweb for a long time, but just joined because everyone seems so helpful. :) ) Maybe someone can help me too. Here's …

Member Avatar for richieking
0
102
Member Avatar for JayGeePee

I'm having a little trouble finding any kind of info on how to do what im going to ask. I have a list menu... How would I, or can I with an onclick event display more boxes. Heres what i mean. When someone clicks on cancel account for instance, when …

Member Avatar for Kraai
0
542
Member Avatar for phoenix1095

hello there guys, was wondering if anyone could help me,im new to C++ and at the moment im trying to make an array of people which then has either an array or list of other variables, it would be an array of people (this would have their details such as …

Member Avatar for arkoenig
0
175
Member Avatar for TinhornAdeniyi
Member Avatar for Iamthecheese

Hello, I'm having trouble translating an algorithm. I'm not sure I coded bits of this correctly, but I'm certain that I have no idea how to compare an item with a node identifier (cannot apply > operator with T,T) but since this is an insert sorted method rather than insert …

Member Avatar for kramerd
0
176
Member Avatar for Austinstig

I'm stuck. I currently have the following example file structure: X, Y, Z 0.000234E+04, 0.000244E+03, 0.000234E+04 0.000244E+03, 0.000234E+04, 0.000238E+05 0.000238E+05, 0.000244E+03, 0.000234E+04 I would like for the Scientific Notation to be converted to float or integer values: X, Y, Z 2.34, 0.244, 2.34 0.244, 2.34, 23.8 23.8, 0.244, 2.34 I …

Member Avatar for Austinstig
0
174
Member Avatar for knan

I have a list [CODE]x = ['abc','1','2','3','def','6','8','5','13','mcg','568','35469','6453'][/CODE] I want the output file in a dictionary as follows: [CODE]dict = {'abc':['1','2','3'],'def':['6','8','5','13'],'mcg':['568','35469','6453']}[/CODE] How can i do this?

Member Avatar for TrustyTony
0
203
Member Avatar for insanely_sane

Been working on this for 2 hours non stop. Can't seem to figure out exactly what's the problem. Perhaps I'm taking a wrong approach to this problem. Right, I need to copy a singly linked list to another new list. Can use any method EXCEPT RECURSION. Here's the code so …

Member Avatar for Taywin
0
3K
Member Avatar for sairakhalid

i want to know whats the error over here. i just want to store the three value in a node and making a linked list but after storing two nodes that is headptr and than temptr, when the third node is made it stops. I think my error is somewhere …

Member Avatar for sairakhalid
0
171
Member Avatar for hamza123

My question is that what is the effect if I delete a pointer in a linked list by mistake??? What problems will arise and how will I come to know that is a missing pointer that is causing the trouble?

Member Avatar for hamza123
0
94
Member Avatar for henryford

Am I able to read or write to a file with this code or what is stumping me. The following is what I am suppose to do. Calculate each employee’s pay, and write it out to a sequential file. Be sure to include file I/O error handling logic. Include only …

Member Avatar for slate
0
170
Member Avatar for ptemedia

Hi I have been searching many forums including this one and not found the answer to this anywhere (sorry if it has been and I have missed it) I have a drop-down list in my website. The user can use this to browse the categories and then select a product. …

Member Avatar for ptemedia
0
464
Member Avatar for king_koder

How do I sort a list in Python alphabetically? The code that is used for Python 2 doesn't seem to work: [CODE=python] mylist.sort() [/CODE] Since the file I'm working with has all text in the same case, case doesn't matter here. Please help. Thanks.

Member Avatar for king_koder
0
218
Member Avatar for James0l9l

I am attempting to create code where the user can alter the A elements in the list continuously. If another letter in the list is replaced however, it should ask for new input from the user, and go back to the code where the user can alter A elements in …

Member Avatar for TrustyTony
0
145
Member Avatar for Malinka

Hello Everyone, I have a list of digits. What is the most efficient way to count the number of tokens between two known digits? Here is what I came up with: [CODE] def dis(l, a1, a2): i1 = l.index(a1) i2 = l.index(a2) distance = i2 - i1 - 1 return …

Member Avatar for TrustyTony
0
119
Member Avatar for king_koder

Hi, How do I find the frequency of each item in a list in Python? For example if there are five 'apple', two 'banana', and so on in the list, how do I write a program so that it displays the item as well as the number of times it …

Member Avatar for woooee
0
176
Member Avatar for knan

I have dictionary with single element lists. [CODE]dictionary={'a':['A'], 'b':['B'], 'c':['C']} [/CODE] How can i change it to [CODE]{'a':'A', 'b':'B','c':'C'}[/CODE]

Member Avatar for TrustyTony
0
147
Member Avatar for knan

I dont know what goes wrong in this piece of code?!! I keep getting the following error. File "<stdin>", line 11 t1.append(list[temp]) ^ SyntaxError: invalid syntax [CODE]tl = [] for inlist in token_list: temp=[] for token in inlist: temp.append((zlib.adler32(token,65521)) tl.append(temp)[/CODE]

Member Avatar for Gribouillis
0
155
Member Avatar for knan

I have a list of lists [CODE]x=[['a', 'b', 'c', 'd'], ['e', 'f'], ['g', 'h']][/CODE] I need the following output. [CODE]a-b a-c a-d b-c b-d c-d e-f g-h[/CODE] How can i do this? Can a regular expression be used here??

Member Avatar for Gribouillis
0
149
Member Avatar for RykeTech

I am unsure how to describe this question, but I'll try my best. I am building a website in XHTML and have the text in a div over the background, which contains a box that I position the text in. Is there a way to get the box in the …

Member Avatar for ko ko
0
124
Member Avatar for VectorAKA

I have been messing with this program for my class for days now. I can get the program to run fine....I can get it to return highest value in list but i need it to return the month it occurs in. Here is the exercise as it appears in my …

Member Avatar for Schol-R-LEA
0
5K
Member Avatar for Knome

I've searched all over google and this site. I've found a few hints here and there but after i make the changes either my compiler throws a fit or it doesn't produce the desired results. Here's what i want: I want to create a linked list in the main function …

Member Avatar for Martin B
0
4K
Member Avatar for krazyito65

[code] class Node { private: int integer; Node *pointer; public: Node(int x = 0, Node *y = NULL) { integer = x; pointer = y; } int getInteger() { return integer; } Node getPointer() { return *pointer; } }; [/code] [code] private: Node *stack; Node *top; int listSize; int pushedValue; …

Member Avatar for krazyito65
0
217
Member Avatar for Smithy566

Hi all, to simplify my problem, I'll use a quick example. Imagine I have a class of 'Cat' which has accessors for things like 'name', 'colour' and 'height'. I then put these cats in a list [CODE]List<Cat^>^ catList;[/CODE] I want to be able to search this list based on the …

Member Avatar for Ancient Dragon
0
1K
Member Avatar for ilkeamasya

I have an win32 console phonebook application. Phone records are held as linked list. [CODE] struct Tel_dugum{ char name[NAMELEN]; char telno[TELNOLEN]; Tel_dugum *next; }; [/CODE] You can see the structure of the linked list above. My problem is when i search i dont want my app to search whole records …

Member Avatar for vijayan121
0
116
Member Avatar for corby

Here are my questionsand my answers. Could you guys/gals tell me if i am right or wrong? Which array-based operations are O(1)? inserting item or deleting item in unsorted array Which linked-list operations are O(1)? inserting and deleteing item in unsorted lsit Which array-based operations are O(n)? traversing through the …

Member Avatar for corby
0
98
Member Avatar for dantheman50_98

Hi There, - I've got a list similar to the following: <ul> <li><a href="item1.php">item1</a></li> <li><a href="item2.php">item2</a> <ul> <li><a href="item2-5.php">item2-5</a></li> </ul</li> <li><a href="item3.php">item3</a></li> </li> - Item 2 needs to have a class added to the li using jquery. I've tried the following but it isn't working: <script> jQuery(function(){ $(this).parent('li').addClass('current'); }); </script> …

Member Avatar for dantheman50_98
0
152
Member Avatar for Overachievious

Hey, I am working on a program for my class where we are supposed to count the letters that occur in a given string, with decreasing frequency. For instance, it would say there are 150 A's, 234 B's, 25 C's, etc. Plus, it would then become possible to sort the …

Member Avatar for TrustyTony
0
222
Member Avatar for knan

I have 2 lists X=['a'] Y=['b','c','d','e','f'] I need to make a new list Z such that, Z = ['ab','ac','ad','ae','af'] I know this uses simple concatenation. I tried several times but without success. I am a beginner so please help me with the code. Thanks in advance.

Member Avatar for Gribouillis
0
112

The End.