Questions tagged as 'lista-encadeada'

1
answer

Program Stopping Responding in C - Chained List

I'm doing a college job in C and I've pretty much finished the same. However, I've threaded a bug that I can not seem to get out of. My program, while passing the line aux1=aux1->next; simply stops working. It stops responding as it do...
asked by 06.05.2017 / 01:32
1
answer

Sorting in Double-chained List Circular in C

I need a little help here with Double-chained Circular List to solve a bigger problem. I need to do a function that already inserts my elements in descending order. My code even works with entries that only need to be reversed. Ex: 1 2 3 4...
asked by 02.10.2016 / 22:17
0
answers

How to make a linked list with Javascript that points to an element I want?

Example: I have an array of blocks, each block has a process object that has a state attribute, which can be either free or busy. How do I make every free process point to the next free process even though processes are busy with each other?   ...
asked by 06.05.2016 / 22:09
1
answer

read from binary file to linked list c

Well, I'm having a problem reading the information from a binary file and inserting it into memory in a linked list. PERGUNTAS val; lista_perguntas * aux = original->next; lista_perguntas * base = original; lista_perguntas * novo; while...
asked by 28.05.2016 / 15:26
2
answers

Create list chained with realloc ()

I need to implement a list that is simply chained that does not have an indication of next, that is, it should work as a vector, accessing nearby positions in memory. I am using the realloc () command to try to implement, however I am getting er...
asked by 29.09.2015 / 03:57
1
answer

Why can not I print content in Linked List

Good evening, I have a problem with a college job. I need to create a linked list that receives student records. I created a function to register, however, I can not externally print the contents of it using the first one's pointer. I would like...
asked by 24.10.2015 / 02:28
0
answers

I can not assign a value to the last element of an array

struct Numero {         ishort num;         Number * next;     }; ishort array[3]; array[0] = grid1; array[1] = grid2; array[2] = grid3; array[3] = grid4; ishort i = 0; Numero *n; Numero *t; Numero *h; //lista circular while(i <= 3) {...
asked by 06.10.2015 / 00:21
2
answers

Error to print on screen a name in C, using threaded list

I made this code with the purpose of asking for notes and names and then printing on the screen, so for some reason the name n is being shown the name that was entered. The code was made in C. { #include <stdio.h> #include <stdlib.h>...
asked by 23.05.2018 / 21:55
1
answer

What is the complexity of each of these functions?

Simple circular list implemented in C #include <stdio.h> #include <conio.h> #include <stdlib.h> typedef struct s_no{ float info; struct s_no* proximo; } no_t; no_t* cria (){ return NULL; } no_t* insere (no_t* l...
asked by 09.04.2016 / 15:52
1
answer

Double-chained List Problem

My function - for now - can create a list and add items at the beginning or end of the list. However, when calling the add item function, selecting 1 or 2, and typing the item, the program simply exits. I can not find what the problem is, follow...
asked by 31.12.2018 / 05:54