Hello
Thanks for your help
Sending a google drive link where you have the program and a txt file
After running choose option 2 and put one of the id (1 to 20)
Google Drive: Sign-in
Type: Posts; User: Gil Carvalho
Hello
Thanks for your help
Sending a google drive link where you have the program and a txt file
After running choose option 2 and put one of the id (1 to 20)
Google Drive: Sign-in
Ok
I have changed the way the information was saved into the file using a structure
struct medicos
{
int idMedico,telefone, salario, anos, idade;
char localidade[100],...
Well, iv'e been trying to fix that with fgets, fread...changed from txt do dat and still no way of getting this working.
can you help me please?
Thanks
Thanks for your info
Can you point me to the right direction please?
When i hit 2...
Process returned -1073741819 (0xC0000005) execution time : 14.598 s
Press any key to continue.
What do i...
Hello
I'm having problems getting the name of the record saved in txt file.
So i ask the user to choose an id and the name must be retrivied but it only works with fisrt line
This my code
...
Hi
I would like to say thank to all of you who have helped me with all my stupid questions, slow learning and taking me out all my doubts.
I know i was a boring man.
Many thanks:rolleyes:
Hi Andreas, now it works.
With the qsort.
Many thanks
regards
The sorting algorithm used by this function compares pairs of values by calling the specified comparator function with two pointers to elements of the array.
The function does not return any...
4 are the numbers i want to sort.
To Andreas:
the print is the following:
4 Top de jogadores
*=============================================================================*
Before qsort
Hi
Already did some progress but the data comes unsorted
int comparador(const void * elem1, const void * elem2)
{
return ((struct jogoJogado *)elem1)->res_final = ((struct...
Thanks
But i need to read the file into an array, right?
file xx
int array[200]
array=(fread.....
Hi
Can someone tell me how can i sort my file created?
The file writed comes from a struct
The fields are char name , float total, int result
My file is printed like this
Ok Thanks
I don't have fseek anymore but still not working
int listarJog()
{
struct jogador j;
Hi....again
I was testing my program then i realise that i have a bug in my code.
Well, i have a struct file with nickname and pass
When i use the fread i see 3 registered users.
When i...
Hi
The listarTop is called like this
listarTop(&j)
I just found out what was the problem, AndiPersti you gonna kill me with all reasons, arguments where in different order.
I think it's not necessary to use malloc since the assisgment don't specify it's must be.
So i use a regular fread file
int listarTop(struct jogador *j)
{
int retorno, cont = 0;...
Hi (again)
Hope this is my last post asking some help...
I have a function to see my registered players but i must use malloc
int listarTop()
{
Hi AndiPersti
Yes, at least, took ages to understand but now i think i get how does this work.
Thanks for your help and patience :)
AndiPersti
Now yes, i think i get it
gp2_Ques(usr1, &result, &total_perg, &certas, &erradas);
....
I forgot to mention...
The problem is in function gp2_Ques
The printf of variable erradas gives me memory adress
Thanks
Hi
I really thank you all for helping me with this.
My main doesn't start like this, but i'm sendind all functions envolved in this subjet.
Firts let me explain that main function are...
Well, i think i'm starting to get it but i still have a memory adress in function 2 then all rest will have wrong values.
So,
gp2_Ques(usr1, &result, &total_perg, &certas, &erradas);
Ok, thanks
Iv'e made some changes like you told me.
int
gp1_Ques(struct
perg *p, char
*usr1)
//function call
Well, i think is better to put all my functions and prototypes.
Maybe there is something wrong
int gp1_Ques(struct perg *p, char *usr1)
//function call
gp2_Ques(&p, usr1, &result,...
Sorry christop
my current prototype is
gp3_Ques(usr1, &result, &total_perg, &certas, &erradas);
Compiler warnings