2,180 Topics

Member Avatar for
Member Avatar for Mar. Na.

Hi all, How can I use linked list for files ,, For example : Class C extends B Class B extends A So, if I want to reference to C and when deleted extends from first statement , the inheritance must be stoped and not point to B ... Can …

Member Avatar for Mar. Na.
0
459
Member Avatar for Roger_2

i cannot find a reliable source online that explains the proper syntax and my instructor's help is negligible. Please any insight is greatly appreciated. This is my last study guide question for my final later today! the problem is identified with arrows below. i was provided source code to a …

Member Avatar for JamesCherrill
0
552
Member Avatar for n00b321

#include <iostream> using namespace std; //Linked List: Delete a node at nth position struct Node { int data; Node* next; }; Node* head; //Global void Insert(int data) { //Insert an integer at the end of list Node* temp1 = new Node; temp1->data = data; temp1->next = head; head = temp1; …

Member Avatar for n00b321
0
9K
Member Avatar for Gede_1

#include<stdio.h> #include<stdlib.h> struct node { int data; struct node *next; }*head; void append(int num) { struct node *temp,*right; temp= (struct node *)malloc(sizeof(struct node)); temp->data=num; right=(struct node *)head; while(right->next != NULL) right=right->next; right->next =temp; right=temp; right->next=NULL; } void add( int num ) { struct node *temp; temp=(struct node *)malloc(sizeof(struct node)); temp->data=num; …

Member Avatar for AssertNull
0
6K
Member Avatar for MirorB

There are 3 JTextfields that are supposed to display info in each one after you click List Info and brings you to a new GUI and you automatically see the info in the JTextFields, but it's not displaying anything. Also I'm using Eclipse and SQLite Manager if that helps. Iogin, …

Member Avatar for MirorB
0
432
Member Avatar for blacklune

Hello, I have been struggling with this project for several days. This is all about doubly Linked List and I have to add reverse section with given code in project. So far it was doing good. I learned a lot from this but the only thing I had issue is …

Member Avatar for AssertNull
0
285
Member Avatar for brandon66

#include <iostream> #include <iomanip> #include <stack> #include <queue> #include <vector> #include <fstream> using namespace std; class graph { public: graph(); graph(int); //graph(int, int); void setEdge(int src, int dst); void printGraph();//print graph void bfs(int);//Breadth First Search void dfs(int);//Depth First Search void bfsSpan(int);//Breadth First Search Spanning Tree void dfsSpan(int);//DepthFirt Search Spanning Tree …

Member Avatar for brandon66
0
521
Member Avatar for Joseph_19

write a c++ program that can use a linked list to store10 studets records with following fieds,reg no marks and grade.program shoould be able to enter records one after the other and display results

Member Avatar for rproffitt
-1
51
Member Avatar for negru

Create doubly linked list that has the following information about **books**: **book_id, book_name, author_id, book_price**. Sort list in ascending order by **book_price** using bubble sort algorithm. Delete all books with the smallest and the largest price. How to modify the following program such that the sorting is done using bubble …

0
169
Member Avatar for MantArray

hello, i am new to link list in java, the output() method isn't displaying the last value entered by the user, can i get some help? also you will see some commented methods that i still need to create, if would be of much help, if you can get me …

Member Avatar for JamesCherrill
0
269
Member Avatar for Vessy

I have to do this program in C++ but I don't know how exactly to write it so that it displays everything it has to display. I'll be really thankful if you try to help me because I'm not so good at programming. 1. Create a program that has linked …

Member Avatar for rubberman
0
348
Member Avatar for khaled02

Hi, I hope you can help me out of this because i really dont understand how to fix this code anymore, i tried and tried and it don't work. When i debug this code in Microsoft Visual Express 2010, it says the following erros are: 1>------ Build started: Project: Adreesbook2, …

Member Avatar for khaled02
0
241
Member Avatar for ayeswarya

[CODE]struct PCB* handleProcessArrival_PP(struct PCB *processhead,struct PCB *processtail,struct PCB *currProcess,struct PCB *newProcess,int currTime){ if(currProcess==NULL){ newProcess->executionStartTime = currTime; newProcess->executionEndTime = currTime+newProcess->totalBurstTime; newProcess->remainingBurstTime = newProcess->totalBurstTime; if(newProcess->processID==processhead->processID){ processhead= newProcess->next; printf("processhead in case 1 %d \n",processhead->processID); } currProcess=newProcess; printf("***current process = new process%d \n",currProcess->processID); contents(processhead); return currProcess; //return processhead; } if (currProcess->processID !=0){ contents(processhead); if(currProcess->processPriority>newProcess->processPriority){//new …

Member Avatar for rubberman
-1
3K
Member Avatar for Gà_1

I'm writing a simple program to figure out how Linked List works, but for now I'm stucking. I don't know which line cause the error or I had a mistake in thinking. I run my program by my hand and it works fine. But when run, it gets error at …

Member Avatar for Beingmahendra
0
217
Member Avatar for negru

I need some explanation with the logic in the following program: Create a data structure such that it contains of three singly linked lists that are connected to one central node. **i-th** list can only have elements such that **list_element % 3 = i**. First element of every list represents …

Member Avatar for tinstaafl
0
351
Member Avatar for negru

The following program should create singly cyclic linked list which has **n** nodes, where data are random generated numbers from **0-99**. Create binary search tree which will contain all prime numbers from the list. Print binary tree in text file so that numbers are sorted in descending order and every …

Member Avatar for rubberman
0
406
Member Avatar for negru

I need help with the following program: Create a structure **STRING** which represents a string ( as singly linked list). Check if the string is a palindrome using stack and function which prototype is **int palindrome(STRING *str);** Code: #include <stdio.h> #include <stdlib.h> typedef struct { char *info; }STRING; typedef struct …

Member Avatar for rubberman
0
1K
Member Avatar for LinuxGuy80

My question may be unclear but, can integer pointers be in any type of data structure? I mean like in a list, tree, graph, etc. Like say a linked list: struct list { struct list *next; int *some_data; }

Member Avatar for rubberman
0
169
Member Avatar for Emily_2

I'm trying to write a program that has a user input student names, their ages, their GPAs, and their graduations dates (i.e. 'F13', F for Fall, S for Spring, then the last two digits of the year). This information goes into a linked list, then the user can search a …

Member Avatar for David W
0
367
Member Avatar for kstin

I am terrible at C++ coding and have no idea how to write this code. Could someone please help me?? 1. Modify the linked list class you created in the previous programming challenges by adding a member function named reverse that rearranges the nodes in the list so that their …

Member Avatar for zelrick
0
152
Member Avatar for sing1006

I had 3 datagridview in visual basic, and each of them is linked to each other. 1 Main component can have many Failure Mode and 1 Failure Mode can have many Critical. [Click Here](http://i1333.photobucket.com/albums/w631/lloyd1006/1_zpsapbu0wla.png) [Click Here](http://i1333.photobucket.com/albums/w631/lloyd1006/2_zpsbe2c2u3n.png) [Click Here](http://i1333.photobucket.com/albums/w631/lloyd1006/3_zpsw2s2weo6.png) I want to duplicate selected row or record including their children details, …

0
158
Member Avatar for A2h2t

Hello can someone help me to complete a program that allows the user to input names and for the output it should prints the names in alphabetical order. starting would be something like that. #include <stdio.h> struct sort_names { char node_str [80]; struct sort_names *next; };

Member Avatar for rproffitt
0
9K
Member Avatar for ShiftLeft

I'm in the process of designing a console personal/business finance package for Linux. It's easy to identify the advantages of data abstraction through classes, but I'm not inclined to become proficient with STL or containers. Exception handling may become a consideration, but definitely memory allocation via "new". My own implementation …

Member Avatar for ShiftLeft
0
1K
Member Avatar for Aldair -

**Well guys , i have a problem , i have got my linked list , it add numbers (to the list) , and show numbers(from the list ) , but i can´t add the numbers of the list , i really need help , if the list would be: 1) …

Member Avatar for Taywin
0
216
Member Avatar for ravi_14

**Bold Text Here**I am trying to make a generic linked list . below is the code for linkedlist . #ifndef GenericLinkedList_h #define GenericLinkedList_h #include <iostream> #include "GenericLinkNode.h" //class GenericLinkedList; template <typename T> class GenericLinkedList { private : GenericLinkNode<T> *head; public: GenericLinkedList(); void traverse(); bool isEmpty() { return head == NULL …

0
179
Member Avatar for homeryansta

[CODE=C++] #ifndef LIST_H #define LIST_H #include <iostream> typedef char Item; class List{ public: List() {first = NULL; last = NULL;} //~List() void append(Item entry); void remove_last(); void output(); private: struct Node { Item data; Node *next; Node *back; }; Node *first; Node *last; }; #endif [/CODE] I'm writing a class …

Member Avatar for Syed Zuman
0
969
Member Avatar for diafol

## Contents ## Overview 1. Alternatives to Deprecated mysql_* Functions 2. SQL Injection: What to do with $_POST and $_GET variables 3. How to Insert Tablenames and Fieldnames Properly 4. What to do With Dynamic Values? 5. How to Use Aggregate Functions (COUNT, SUM, MIN etc) 6. How to Paginate …

Member Avatar for developer707
6
5K
Member Avatar for Kert

public Set<Product> getProductsByPriceFilter(Map<String, String> filterParams) { Set<Product> products = new HashSet<Product>(); String l = filterParams.get("low"); String h = filterParams.get("high"); BigDecimal floor = new BigDecimal(l); BigDecimal ceil = new BigDecimal(h); return products; } I have discovered an interesting phenomena. I have filterParams that should <String, String>. However, if I use filterParams.get …

Member Avatar for newcoder310
0
357
Member Avatar for negru

How to print path of a binary tree after adding every node (branches of a tree have values 0 and 1)? For example, I have this binary tree: NODE1 has two children, NODE2 and NODE3. Branch from NODE1 to NODE2 is 0, and from NODE1 to NODE3 is 1. From …

Member Avatar for rubberman
0
188
Member Avatar for kikunha

the employees must be registered in alphabetical order, but i don't know how........... struct EMP { int empno; char empName[MAX]; char designation[MAX]; struct EMP *next; }; struct EMP* insert(struct EMP *front, int id, char name[], char desg[]) { struct EMP *newnode; newnode = (struct EMP*) malloc(sizeof(struct EMP)); if (newnode == …

Member Avatar for skaa
0
190
Member Avatar for Alan_7

**Question-1: Write a program to sort in ascending order random entered numbers by user using Linked Lists. - Size of LL is not limited - Entering numbers should be stopped by entering '0' (zero) - Sort entered numbers using any sorting algorithm (Bubble, Selection or Insertion sort) - Display sorted …

Member Avatar for David W
-2
656
Member Avatar for Trabelsi

Hi, first, sorry for my english i am not good at all, I am trying to create a form that contains two drop-down lists , the first is related to the second list , I noticed that the first list of data ( joursemaine ) appears as a question mark …

Member Avatar for Trabelsi
0
255
Member Avatar for alexx006

Hi everyone, I’m beginner and I need a little help. I have to make RPN (postfix) calculator using stack which is implemented by singly linked list in C. Now I found that but in C++ and I’m having trouble translating it to C. Can you help me getting things to …

Member Avatar for Schol-R-LEA
0
297
Member Avatar for ann123

Hey, I need to create a war card game. I have a problem with linked list - I read about it but still I have a problem with writing the code. I made a deck of shuffled card and now I need to sort it out between 2 players... so …

Member Avatar for sandeepjkl
0
149
Member Avatar for vuquanghoang

In my mind, using linked list is somehow abstract. Despite reading posts with similar topic, I still cannot understand how to apply it in to real problem. My teacher gives my this exercise. In spite of not being mandatory, I want do is to understand the problem: Addition/subtraction /multiplication.. . …

Member Avatar for Smita_1
0
883
Member Avatar for liyanaddsce

Hello!!! I am a beginner to C++ and linked list and searching algorithm really made me confused. There are 26 errors (which caused by pointer ofc). Can anyone give me idea how to fix these errors??? #include<string> #include<cstdlib> #include<iostream> #include<malloc.h> #include<fstream> #include<time.h> #include<conio.h> using namespace std; #define SIZE 10 class …

Member Avatar for Moschops
0
274
Member Avatar for ms95

hi i've been given a task to do the following program without using structures or linked list and ... . just with arrays and simple things. the application will accept some data as follow : N1 F N2 N2 F N3 and then print them out from grandfather to son …

Member Avatar for ms95
0
636
Member Avatar for Sdam

define linked list called student name number address and the following function add function that add the information of the student 2 search function that search print the name of all student with some address search ("zarqa,amman,irbid") will print the name of students lives in amman 3 count function that …

Member Avatar for Sdam
-1
542
Member Avatar for mike_2000_17

# Introduction # A recurring problem many newcomers face when tackling C++ is the compilation process, from sources to binaries. This tutorial will detail that process. It will be especially useful for people only familiar with higher-level languages (if any), but veterans of one or more native languages (C, Fortran, …

Member Avatar for Lutina
15
8K
Member Avatar for Thomas_25

Hi all, What is the best sorting algorithm for a doubly linked list? Insertion sort and merge sort appears to the best due to the less overhead compared to the bubble/selection sort. Would like to know your insights on this. Thanks.

Member Avatar for rubberman
0
2K
Member Avatar for Thomas_25

Hi all, can i store multiple data items inside a doubly linked list? is this valid? struct node { int marks; int regno; struct node *next; struct node *prev; }*start; If this is valid, how can i assign values to the individual data items? next->marks=5; next->regno=3456; will this work?

Member Avatar for Thomas_25
0
408
Member Avatar for brandon66

Im trying to implement queue with a linked list i think i have the enqueue function correct but im having problems with the dequeue. I can get it to delete the first number but then the rest of the list is empty can someone point me in the right direction? …

Member Avatar for brandon66
0
247
Member Avatar for geolotry

Hi all I have been struggling with this program for quite awhile. I can't seem to get the PRINTFREE and PRINTMATCH commands to work right. I seen a similar problem on here but I am still grasping at straws. Any help would be greatly appreciated. Here is the scenario for …

Member Avatar for Christopher_11
0
341
Member Avatar for cblue

I was wondering if anyone can give me an idea on how i can modify this function to check for duplicates, if it contains a duplicate, since duplicates are not aloowed, output a message. Any help would greatly be appreciated. [code]template<class Type> void orderedLinkedListType<Type>::insertNode(const Type& newItem) { nodeType<Type> *current; //pointer …

Member Avatar for drussell024
0
3K
Member Avatar for kayleigh0411

I am creating a doubly linked list and printing a backwards function. Everything is working great in my code, but when the function is printed in reverse, I need it to say NULL at the end, as it does going forward. When I put puts("NULL") (line 193) it splits up …

Member Avatar for kayleigh0411
0
281
Member Avatar for Gà_1

**Problems 1: Spiral matrix - Advanced** Source of the problem: [Here (not in English)](http://www.spoj.com/PTIT/problems/BCACM11B/) Spiral matrix is formed by filling number 1 in 1st row 1st column, after that, filling with increasing number by clockwise, example: 1 2 3 4 5 16 17 18 19 6 15 24 25 20 …

Member Avatar for tien.nguyen.3532507
0
378
Member Avatar for Jazmine_1

Hey everyone! So I need to write two header files and they attach to the main cpp file, but we can not change the cpp file. They have to attach and make the program run. Please help! Main cpp CANNOT be changed! //22 34 56 4 19 2 89 90 …

Member Avatar for Schol-R-LEA
0
248
Member Avatar for redtribal23

InputFile.txt Bea Sanchez Junior Math OPS HIGH 17 90 Nicole Sanchez Freshman Science OCC HIGH 13 98 Billy Cruz Senior English OPS HIGH 17 80 #include <iostream> #include <string>; #include <fstream> using namespace std; struct StudentNode{ string firstName; string lastName; string gradeYear; string subject; string schoolName; int age; int grade; …

Member Avatar for deceptikon
0
166
Member Avatar for ryan.legow

So I am trying to make my own version of chmod using C, the modifications are to make lowercase add permissions while uppercase remove permissions (instead of using + or - to add and remove). Also, I am trying to print a help message and exit if the command cannot …

Member Avatar for ryan.legow
0
271
Member Avatar for St John

a c++ program the insert new element at the end of a linked list, and allow a user to search for specific item in the linked list. pseudoode for insrtion of new elements at the end of the list

Member Avatar for Zawar_1
0
161

The End.