Questions tagged as 'c'

1
answer

Compile and Run GUI on Android

I use c4droid to compile C-codes using gcc, in my studies I want to enter the graphical interface, but as I am without a computer I thought of using it on my own android. Well, I installed the GNU Root Debian app, I installed gtk3, glade and its...
asked by 13.06.2018 / 16:34
1
answer

How to implement a generic MergeSort sorting algorithm?

How to implement a generic MergeSort generic sort algorithm (with function pointer and void pointer) in this function? #include<stdio.h> typedef struct{ inta; intb; }XPTO; void criaVetor(XPTO∗v, int n){ int i; f...
asked by 11.06.2018 / 14:32
0
answers

How to implement OPEN SSL MDC-2 Hash using Array byte at data input

Hello, I'm trying to do / learn how to use openssl MDC-2. I found an example ( link ) and I adapted to try to understand. This is functional for data entry via string (char). I need it to work for a data input type byte array. Example: MDC-2...
asked by 25.06.2018 / 20:09
1
answer

Kruskal's Algorithm sorted with selection sort

I am trying to compare two variables of a struct type, however it is returning error. struct aresta{ int v1; int v2; int peso; }; ... aresta peso[62816]; aresta aux; int i, j=0; for(i=0; i<(tamanhoVetor - 1); i++){ int...
asked by 11.06.2018 / 09:45
0
answers

How to use a vector in two different functions?

I want to use this vector biblioteca in the adc_livro function. #include <stdio.h> struct novo_livro{ char titulo[100]; char autor[100]; int ano; int qtd; int codigo; }; typedef struct novo_livro livro;...
asked by 11.06.2018 / 04:30
0
answers

Mount a program that displays user-entered prints

Well, I'm having a hard time putting this together using for, I know how to make a program that displays even or odd numbers up to the number entered, but how do I display how many numbers the user reports in num ? #include <stdio.h&g...
asked by 14.06.2018 / 19:10
0
answers

Queue with insertion of a String

I have seen several codes about creating a queue in C, but all use integers. I wanted to create a queue where I would insert a string, for example, nameAlumnus. This queue would have a maximum of 10 strings. My code is as follows. #include <...
asked by 14.06.2018 / 19:43
0
answers

Doubts about C records

Hello, I have a question on this exercise in the last sentence, it's asking to make a list but it does not say it's to register, but I'm putting the list inside the register to save but I do not know if that's what to do. / p>    Develop an a...
asked by 13.06.2018 / 01:56
0
answers

Problem with if-else

I have a problem when comparing with if-else! I have a function that reads a file and writes in another just what is approved by the if-else, then deletes the first file and renames the second to get the first one's name! it happens that when pr...
asked by 01.07.2018 / 22:04
0
answers

Error in list of structures in C

I'm working on a structure list code, where I have a struct called cad that contains the registration, name, and salary fields. And a list containing a field of type struct cad that stores the fields of the struct cad in list form. So the code l...
asked by 09.06.2018 / 19:22