How do you include 3 numbers at the beginning of this vector without affecting the previous numbers?
I'm trying to do this:
int main()
{
int v[30];
int i,x;
for(i=0; i < 15; i++)
{
printf("Digite 15 numeros");...
I have to do a program in C that shows in the end the average of N numbers greater than 6, but I have already exhausted my ideas on how to solve this.
What I've been able to do so far is this:
#include <stdio.h>
#include <math.h>...
It's a simple code (I'm practicing pointers)
It is not printing the result, the program closes ... why? ;;;
#include <stdio.h>
#include <math.h>
#define PI 3.1416
void calc_esfera(float R, float *area, float *volume);
int main(){...
I made a source code in C, conditional, but when I add a function printf windows reports that the program stopped running.
See the code: 1 : link
NOTE: I USE WINDOWS 7 HOME BASIC, AND MY EDITOR AND COMPILER IS DEVC ++, IF THAT INTERFERE IN...
The program is giving an error when compiling.
else without a previous if
Something about else , is there something wrong with the condition if and else ?
#include <stdio.h>
#include <stdlib.h>
int mai...
#include <stdio.h>
#include <stdlib.h>
void recebeNumCartas(int *nAlice, int *nBeatriz){
scanf("%d %d", nAlice, nBeatriz);
}
int achaMenor(int nAlice, int nBeatriz, int menor){
menor = nAlice;
if (nBeatriz < nAlic...
Statement:
Read a 5x5 matrix. Also read an X value. The program should do
a search of this value in the matrix and, at the end, write the location
(row and column) or "not found" message
Code:
#include <stdbool.h>
#includ...
When I was beginning to learn pointers and dynamic allocation of memory in C, I was told that all memory allocated in the program is deallocated when it is terminated. Ex:
#include <stdlib.h>
int main(void){
int *vet=calloc(10, siz...
Well, I know that in stackoverflow I should not go too far into the subjective when it comes to questions, so I would like you to answer given facts rather than based on your experience.
Well I'd like to start learning how to use a graphic li...