Questions tagged as 'c'

2
answers

Bowling score in C;

I'm new to C and I'm having problems in an exercise, I can not see a way to solve it. Next: At each stage the player has 2 balls with which he must drop 10 pins. The stage ends when: the player knocks down the 10 pins or the player use...
asked by 24.04.2015 / 18:51
1
answer

Problem using the getch () function in C

I am writing a simple game that is based on traversing a number in the first element of the array to the last element. However, I want to use the getch() function so that the element moves through the array immediately after a key is ente...
asked by 17.07.2015 / 03:45
1
answer

Add typed values without using array

Create a program that asks the user to type 10 values, add these results and present them on the screen. I've only been able to do with an integer array. #include <stdio.h> #include <stdlib.h> int main() { int i, soma; soma...
asked by 22.07.2015 / 04:29
1
answer

Storing SOCKET in a vector

I am working on a project developed in c / c ++ where a server handles several connections, I do not have much experience in this language, I would like to know how to proceed to add a SOCKET to a vector, / p>     
asked by 13.05.2015 / 18:35
2
answers

Is it possible to change my server code without having to compile?

Well I was thinking of something, I have a program that is hosted in linux and through an executable, my clients have access, every modification I make in the server code I have to compile again to take effect, this makes it impossible my client...
asked by 16.05.2015 / 18:15
1
answer

How do I have an option that exits the program or keeps running with the others?

You can add a third option when asking the user, and this option will only appear after the first calculation. Ex. (3 exit). I just thought about the way the 3 options come up right from the start. #include <stdio.h> int soma(void)...
asked by 18.10.2015 / 01:51
1
answer

When a header file is included, does the compiler include all the functions in the final program or only the functions used?

That is, is the executable going to have the whole library in it or only the functions that I use will be included by the compiler? With this, can you include many libraries that can make the program cumbersome (taking up a lot of disk space)?...
asked by 09.04.2015 / 21:11
1
answer

Removal item in threaded list C

Well, I'm having a little problem, I'm implementing a simple A *. When I pass the item already checked to the closed list and do the deallocation of the open list item, it is giving undeclared pointer error ... The error is this pointer being...
asked by 25.10.2015 / 04:48
1
answer

How to read a line in C

How to read a row of integers and store in a dynamic-sized vector? I currently read the string as a string (though the input is only integer) using gets, the only way that worked. The code looks like this: type def struct{char entrad...
asked by 12.08.2014 / 19:43
1
answer

Can I only write code with bugs or vulnerabilities in C?

Who is programmer and experienced knows an implicit truth: C is practically the language of the gods. C corresponds to at least 98% of the software running on all computers and thanks to its low level allows for incredible things. However, th...
asked by 28.06.2014 / 03:01