2,179 Topics
![]() | |
This is/was an interview question I got two weeks ago. Find where the loop begins in simple linked list. I hope this figure will help understand what I mean : [code] [LEFT][1] ->[2] ->[3] ->[4] ->[5] ^ | | U [10] [6] ^ | | U [9]<- [8]<- [7][/LEFT] [/code] … | |
I need help... I don't know how to insert data [continuous numbers] from a text file (.txt) into a linked list?? I have been searching for some tutorial abt it but i didn't found any of it. Please help me!!! | |
hello friends could anybody give me idea how i can find a loop in simple linked list | |
Hi all: There are two function declarations in the header file: void sqEnqueue(const char *s); char *sqDequeue(); (no input arguments) Those function declarations can NOT be altered. I created a linked list in this sqEnqueue function, which has the a "first" and a "last" at the head and the end … | |
After exploring PHP for the past few days, I've been trying to use it on the new CSS based website that I'm creating. I'm trying to use "include" function in order to get my "header", "topMenu", "leftMenu", "rightMenu" and "bottomMenu", since in ALL the pages, these would be common. The … | |
Hey guys just wondering how i can sort the linked list by categoryName for the drink type list. Iv done the linked list in my code but its not sorted? Could someone help me write an algorithm or sum pseudocode [code] #ifndef GJC_H #define GJC_H /* System-wide header files. */ … | |
hi, any suggestions on a good reading material or examples about linked list, doubly linked list on the web. or any good book that touches on this`topic very well..thanks bros. I want to keep one for future ;) reference. | |
Hello :-) I have build a task of Linked List but for some reason , after i break the Input sequence by entering the same INT value twice in a row , the menu appears twice . howcome? Thank , Code Attached . Yotam | |
eh hi there, im new on the boards and i see you got a good help section, dunno if this is quite the right place to post this but i really really need help! at college we are creating an online portfolio basically, and mine is yet to be desinged … | |
hi im having problems with a doubly linked list. im trying to initialise three names into the list and print them straight off using the list and pointers but cant figure out how. heres what i have already if it could be modified i would greatly appreciate. also please keep … | |
Sorry for posting again guys but i have fixed up teh string copies to copy the data into each struct variable. But still when i traverse through the linked list it does not print out anything after it reads the file. For some reason it may not be copying at … | |
Hey guys im reading in a text file with several fields iv tokenized the '|' so that it only reads the fields categoryId, drinkType, the categoryName, and categoryDescription. My question is how come when i read the file and copy the reading buffer "temp" into each struct it does not … | |
I have a program project to complete, but I don't know exactly what to do. This program is in C++ programming language. This what I have to do? Write a program that will use a array to store a linked list. Your linked list should contain an Student number and … | |
Bearing in mind CSS needing less code typing than HTML & its capability to merely have one single style sheet that's linked with other HTML document & hence having less codes, I wonder if there's a way that helps me achieve the following: >> I want ALL my paragraph that … | |
Hello all, I am wondering if anyone has any or know where I can get examples of source code using linked list implementation of stacks. It needs to use a class that stores ints that can be retrieved. Anything you all can provide would be great!!!:-| | |
How do you reverse a linked list using recursion, and return it as a string? String backwards(IntNode head): Create and return a string containing the values in the input list, separated by commas, in reverse order. The last number should not be followed by a comma. Spacing within the string … | |
I wrote a program up with linked lists that creates a circular list containing 9 nodes. Each node contains a number (ranging from 1-9) as an item. My question is...in the while loops, how does [CODE]x = x->next[/CODE] cause the pointer to move across the list? [CODE]#include <stdio.h> #include <stdlib.h> … | |
Can anyone tell me why the following ligitimate code does not work, creating a linked list of characters from stdin? struct Nodec { char element; Nodec *edge; }; void Nodecin(Nodec *N) { char c; Nodec *tmp; if (N == NULL) {N = new Nodec;} tmp = N; do { c … | |
just wanted to say heya to everyone first, ok im doing a C++ assigment on linked list but im stuck. i need to write a program that reads records from a text file and then stores them in a linked list. i can read the data from a text file … | |
I have this problem where I have to create a process and then when I am all done i must delete all processes that are created. I have tried to set up a linked list to do this but when i go to implement it it doesnt work>> I have … | |
Write a menu driven program that manipulates a list of students and has the following options: 1- Build list from file 2- Build list from keyboard 3- Print list Use the standard list ADT to build the student list. Student information are (name, level, ID) information please help with this … | |
Hey guys! :D My program implements the vector class however it only shows I know how to use the Vector Class, and not how to develop a code for a linked list :( My teacher says I can just do a copy paste job, which is precisely what I did. … | |
Hi everybody, I am currently working on an assignment on linked lists. I am stuck with parts of the project, and I would be very pleased if anyone could help me. I am supposed to create a linked list of patient records. Each record is identified by a patient ID … | |
ok, ppl...... i've got a new problem...... im workin on a package at my coll here and im doin spreadsheet.... i have to implement it using linked list and am having trouble in deciding what sort of a linked list i use.... Wat i tht of was, i can first … | |
Hello people of Python community, I'm back with (so far) strong will to learn Python, just like you. I remember once, Narue told me that good way to learn different prog. languages is to concetrate on algorithms and data structures and their implementation in language of choice. That way, she … | |
I am building an online music video library where u can strean the media to ur browser mobile phne and pda devices. I am using PHP for the middle HTML for the front end and MYsql for the backend. I want to have database with the music files residing on … | |
Iam Trying to implement a basic text editor in c++. I've used a doubly linked list for storing the typed characters in a line and have implemented another linked list (No 2)to store many such lines for a document... When i try to save the file using list No2,i find … | |
help me with this code please.this code is for selection sort using linked list.please check it and give me suggestion. [code] #include<iostream.h> #include<conio.h> void main() { struct mylist{ mylist * nxt; int val; }; int a,b,c,d=1,i,j;mylist * t; clrscr(); cout<<"Enter the no&the total no of numbers"; cin>>a>>b; mylist * head=new … | |
the specific problem is that there are no errors in the prob but it is giving segmentation fault.plz check it #include<iostream.h> #include<conio.h> void main() { struct mylist{ mylist * nxt; int val; }; int a,b,c,d=1,i,j;mylist * t; clrscr(); cout<<"Enter the no&the total no of numbers"; cin>>a>>b; mylist * head=new mylist; … | |
how can i save the content of a linked list to a file, plzzz help me :confused: | |
hi every 1 i wanna to ask about sigl and double linked list *what is the advanyages and desadvantegs of the double linke list *when we use the double and when we use the single thanks | |
I want to merge 2 linked list into 1. Is the code below ok? Can you Check please? [code] LIST Merge_List(LIST P,LIST Q) { HEADER h = P; NODEPTR ptr2 =Q; NODEPTR ptr1 = P; NODEPTR prev=P; NODEPTR temp=NULL; /* Second List Pointer */ while(ptr2 != NULL) { /* First … | |
Please I need help on how to insert elements into a sorted linked list.I actually have a list that contains names and scores for students and I want the elements to be inserted into the right postion such that the names of individual students are arranged alphabetically. This is my … | |
I'm a relative new comer to development and need some assistance in writing a function. Here are the requirements: Return the 5th element from the end in a singly linked list of integers, in one pass, and then provide a set of test cases against that function. Any ideas? Thanks … | |
please send me a program of SRTF using c++, using linked list... i'm realy spending days trying to do it but i cant get it right so i need a basis for me to do it my own.... | |
Hi, These are some of the few questions for which i couldn't find answers. :lol: . I was just hoping if any of you can help me out. 1.Write a "Hello World" program in 'C' without using a semicolon. 2.Write a C++ program without using any loop (if, for, while … | |
So I have to make a UNIX shell that can basically take in any UNIX command and then keep a record of the time each process took, by forking off children processes, recording their time, and recording the parent's time, and then return that time into a linked list or … | |
[B]Intro[/B] If search engines determine that your website is popular, then they will list it as relevant to a search, the more popular - the more relevant. The more relevant, the higher you will be listed in search results. But how easy is to be popular? [B]Design to become popular[/B] … | |
hey guys, im a new guy here in the forum and im also an IT student who gets into C++ troubles most of the time, but enough about that... i just wanna ask if anyone can help me in my linked list problem, i think its about pointers and address. … | |
hi friends ... this is my 1st post ...m sure it gonna be beneficial to me.. wel m facing problem in dis assignment..as m nt dt gud in c++ programmin...pls help me out .....we have to use doubly linked list...n ya if its possible in Borland's C++ Builder6(pro)2005 compiler....as in … | |
i was wondering how to delete an element or replace an element from a linked list | |
i've been stuck with linkedlist, can't get my head to think of how it works...i have and assignement on this. i have a few questions that maibe you guys could help with. I'd appreciate it thanks in advance! 1.sorting numbers 2.takes either an integer or ListNode reference and removes that … | |
I am having a small problem removing ALL items from a linked list. I have written a function that will remove all discharged patients from the linked list. [code] [COLOR=Red] for(int a=1;a<(S.size()+1);a++) { int x=S.retrieve_status(a); if (x==5) { S.remove(a); } }[/COLOR] [/code] in this function I check to see if … | |
what I am trying to do is retrive the "status" back to my main prog of the status of a patient. I thought it was a simple case of S.retrieve(index of person I was looking for) and I would recive the status (which is an integer) back to my main … | |
the following code will print out all the names of patients I have in a linked list. I have given the user an option to choose which patient they would like to move in the linked list. i thought if I called S.insert(passed the new postition, and P (where P … | |
Below I have attached 4 methods from my linked list class. 1) find 2)remove 3)retrieve 4) Insert. what I'm trying to do is write code that will let me MOVE the position of a node to another position in the linked list. Anyone got a clue?? regards Tim [code]SeqItemType Sequence::retrieve(int … | |
Hello, I get the following seg fault error when I try to delete the last node of the list. Does anyone know why? My delete function and high level function are included below: The seg fault only occurs when the if value in BeginQuizFirstTry detecting that CheckAnswer is not true … | |
I am having trouble trying to implement my recursive method for inserting into a linked list. I made the recursive method private because it needs acces to the head pointer. Not sure where to go from here . Any help would be appreciated. Here is the code. The .h file: … | |
hi folks, plz try sending answers to folllowing questions....i know they are a lot..still...send as many as possible..... Write a "Hello World" program in 'C' without using a semicolon. Write a C++ program without using any loop (if, for, while etc) to print numbers from 1 to 100 and 100 … | |
Dear All. I have a small problem with the code attached. I am trying to add an object to a linked list. When I try to compile I am getting an error. For the life of me I cant figure out the error. this is after 5hrs of head wrecking … |
The End.