Questions tagged as 'c'

1
answer

Determine that a number is divisible with another number in C

I hope you can help me with this: #include <stdio.h> int main() { int a, b, c; printf("ingrese 2 numeros: \n"); scanf("%d%d", &a, &b); c=a%b; if ((b<a) && (c==0)) { printf("es divisible\n")...
asked by 04.04.2017 / 02:06
1
answer

Problem with the execution of the program

What I want to do, is for the user to enter a text, then in the formaTabla function that compares the string entered with the ones stored in the table and if the string is not repeated, save it in the table . The problem I have is that...
asked by 03.02.2017 / 13:59
1
answer

Problem with nested structures

I'm doing an exercise where I have to load student data. I do it using functions using structures. I have a syntax problem of how to save a data in a nested structure. I tried to do it like this: a[i].fe.dia; And I get the following erro...
asked by 31.01.2017 / 14:45
2
answers

Exercise string management (Strings) in C [closed]

I wanted to know if you can help me by passing me, if you have or know, chain management problems. I have searched the Internet but they are always about encrypting, decrypting chains, replacing characters, investing chain, counting occurrence,...
asked by 15.10.2016 / 20:04
2
answers

Help with program C get Mac Addres

Hi, I would like to know if you could help me with the following error that the program throws at me, it consists of three codes which are: Lic2.h - > which is the header #ifndef _LIC2_H_ #define _LIC2_H_ #define LIC_OK...
asked by 16.11.2016 / 17:12
1
answer

Exercise list linked in C (RADIO)

I am trying to do an exercise in C of linked lists in which I first create a person structure and then I make another speaker which will have a person structure. I use a list to make the records. The problem is that it lets me make a record a...
asked by 26.06.2016 / 05:28
5
answers

Help with decimal numbers in program in C?

How about, I'm doing a project in C, an issue has arisen that I hope the community can help me. I'm using decimal numbers specifically the data type is Float. When printing my output I see that C is doing a kind of rounding. For example: T...
asked by 13.04.2016 / 16:07
1
answer

FILE data structure fields in C (gcc)

I have a question with the fields of the FILE structure in C. For example, if I access the fields in this structure with MinGW32 5.1.4, I would get the code below. However, I do not know what these fields are with the gcc compiler, since this st...
asked by 11.12.2018 / 16:50
2
answers

Chain Arrangements

How can I store strings in a C array? For example I want an arrangement where I can save 3 names arrangement="juan", "Pedro", "Santiago"; juan in position 0 of the arrangement Pedro in position 1 of the arrangement Santiago in position 2 o...
asked by 30.11.2018 / 03:03
1
answer

typedef struct MyStruct MyStruct ;?

I am reading a book of design patterns and use the typedef in the following way. What would be the function in this case? typedef struct MyStruct MyStruct; struct MyStruct { char var_1 ; char var_2 ; }     
asked by 07.12.2018 / 23:28