I can not use fscanf in a structure, I have already allocated structures.
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
struct Cliente
{
int numero;
char *nome;
};
struct Filme
{
int numero;...
#include <stdio.h>
#include <stdlib.h>
int main()
{
int matriz[5][5];
int i, j, posicao=0;
int maior = matriz[0][0];
int menor = matriz[0][0];
int posicaoI=0, posicaoJ=0, posicaoi=0, posicaoj=0;
srand(t...
I'm developing the rooster / old game and in this game I have to check every new move or iteration if there is any winner. I started by trying to do this for a static array predefined by myself and also started by doing the check first by deleti...
Recently I've been wondering if it's possible for the compiler with some flag optimization, avoid copying two arrays to the .rodata section? Thus, memory addresses would be the same, eg
const char str[7] = "string";
const char str1...
I'm trying to solve a problem early on which is as follows:
A school wants to know if there are
disciplines Logic and e Programming language. Enter the numbers
of the students that study the Logic in a vector at most
of 5 students. E...
This code is a simple register of people, containing code and the person's name.
I am confused as to passing the struct vector to the "insert" procedure.
When compiling, the program stops working. In the compiler I get the following error: "P...
I'm trying to create a DLL with the code that the teacher passed, but it does not compile properly. The warning is appearing:
"No local application has been provided, you can set it in the Run menu, Parameters"
What would these Par...
I wanted to create multiple .txt files and did this through a loop, and I did. But the only way I can read all the files is by doing another loop, for example: it does a looping of 3 passwords, that is, I created 3 passwords, 3 .txt files, but a...
I am trying to do operations using stack but at the time of allocating the results in the previous position in the stack it is that I am not succeeding because the result of the operation is not allocated in the desired position:
I'm trying t...