15,550 Topics

Member Avatar for
Member Avatar for ThatBitchYeah

I have no idea hw to approach this... i need to end my program, shown below by the user pressing the letter Q on the keyboard. Help? #include <stdio.h> #include <stdlib.h> float subtract(float x, float y); int main (void) { float x, y; printf("Please enter a real number:\n"); scanf("%f", &x); …

Member Avatar for ThatBitchYeah
0
333
Member Avatar for saurabh.mehta.33234

I read the following points related to side effects in gnu c manual it is necessary for the following points to hold true between two sequence points: 1.an object may have its stored value modified at most once by the evaluation of an expression 2.the prior value of the object …

Member Avatar for deceptikon
0
131
Member Avatar for anestistsoukalis

I think that the problem is in lines 59-63 #include <stdio.h> #include "genlib.h" #include "ctype.h" #include "simpio.h" #include "string.h" typedef struct{ char name[30]; long sell; double supply; }domiT; void ypologismoi(domiT stx[],int *p,FILE *infile); void emfaniseis (domiT stx[],int *p,FILE *outfile); main() { int p; FILE *infile,*outfile; domiT stx[100]; ypologismoi(stx,&p,infile); emfaniseis(stx,&p,outfile); system("pause"); …

Member Avatar for tinstaafl
0
208
Member Avatar for pooja.singh.3950

How to find this series without using power function in c 1+x/1!+x2/2!+x3/3!+x4/4! please help me out i'm unable to solve these type of questions

Member Avatar for corby
0
135
Member Avatar for ThatBitchYeah

I have an assignment in which i have to add, subtract, multiply and divide two complex numbers and i am very confused as to how to create the program. This is what i have got so far.. #include <stdio.h> #include <complex.h> int main (void) int real, imag; { complex a, …

Member Avatar for ThatBitchYeah
0
1K
Member Avatar for pooja.singh.3950

There is error in this program it's not showing the correct output so help me out by modifying it. #include <stdio.h> int power(int n1,int n2); int main() { int base, exp; printf("Enter base number: "); scanf("%d",&base); printf("Enter power number(positive integer): "); scanf("%d",&exp); printf("%d^%d = %d", base, exp, power(base, exp)); return …

Member Avatar for Gonbe
-1
101
Member Avatar for saurabh.mehta.33234

In the book called gnu c manual I read that the following code has an undefined behavior `i=++i +1`; Because since the variable i is modified more than once between the sequence point,it is not sure that what value will 'i' have..But it is evident that the final value in …

Member Avatar for saurabh.mehta.33234
1
114
Member Avatar for xxwikkixx

Hey everyone I was working on a small tool and also refreshing my programming skills. my problem is I want to pick a random number from 60,000 to 200,000. it does that but the number it displays are not dramaticly changed. For example if it out puts 062045, i hit …

Member Avatar for vijayan121
0
190
Member Avatar for Slayer_Dude_420

Dear Internets, I am currently trying to write a program that can extract the "header" from a FASTA file. and then output a portion of the header to a new file. The part of the header i need is the "CONTIG_X" part. When I run this program it prints duplicates …

Member Avatar for Slayer_Dude_420
0
106
Member Avatar for christodoulos14

hello i have the following file: 11 Lockers, Daniel;Engineer;53500 Adamson, John;Manager;77500 Newhall, Bob;Programmer;40000 Brown, James;Clerk;28000 i need to put each employee into a struct and then each struct into an array. so far i did this: else { fscanf(sourcefile,"%d\n",&count); printf("%d\n",count); Array=(employeeType *)malloc(sizeof(employeeType)*count); for(i=0;i<count;i++) { fscanf(sourcefile,"%s",Array[i].name); fscanf(sourcefile,"%s",Array[i].job); fscanf(sourcefile,"%d",&Array[i].salary); } } for(i=0;i<count;i++) …

Member Avatar for christodoulos14
0
265
Member Avatar for saurabh.mehta.33234

how to print the foll string without using any kind of variable "How are you %dad%"

Member Avatar for Gonbe
0
154
Member Avatar for kw42chan

Dear all I write bubble sort program for inputing 9 numbers. However, when compile and run it, it only allows me to input one number only. Could anyone see any fault in my code? I think the problem is on the first loop. #include <stdio.h> int main(void) { int num1 …

Member Avatar for kw42chan
0
267
Member Avatar for Frederick Sekyi

am frederick sekyi and am new to this website.can any of you help me with computer programing?

Member Avatar for <M/>
0
166
Member Avatar for LDaneil

I am working on a project about data mining. my company has given me 6 million dummy customer info of twitter. I was assigned to find out the similarity between any two users. can anyone could give me some ideas how to deal with the large community data? Thanks in …

Member Avatar for Adak
0
964
Member Avatar for Bchandaria

How to make simple games in c language? did any one of you can help me to build a game?

Member Avatar for rubberman
0
77
Member Avatar for you207

My program is nearly done.But my function SumN doesnt print the correct output. SumN have to output the Sum of numbers that belong to the interval [a;b]. Example: input a=1 b=10 1 4 13 45 10 output sum=15 but im getting 60 and in should be 15. Can sameone help …

Member Avatar for deceptikon
0
324
Member Avatar for kent.johnstone

I need to convert a DWORD into 4 bytes to send to serial RAM. All the examples of using SPIRAM, EEPROM and FLASH use `*variable` to send and receive. I can break the DWORD down into bytes which I stuck in a `char[3]`. I don't, apparently even with all my …

Member Avatar for Ancient Dragon
0
206
Member Avatar for BHARGAVI2

I have a problem. It is to generate a C code Please tell me how to display a image file on the screen in C? If u r kind to me, send the code

Member Avatar for Ene Uran
0
144
Member Avatar for pooja.singh.3950

How to find this series without using power function in c 1+x/1!+x2/2!+x3/3!+x4/4! please help me out i'm unable to solve these type of questions

Member Avatar for Ene Uran
-1
171
Member Avatar for abdelrules

Hello, I am fairly new to c and i am finding it hard to spot why a part of a program I am making is not working. The program lets you work out the area and circumference of a circle. This is the code: #include <stdio.h> #include <math.h> int area() …

Member Avatar for Gonbe
0
232
Member Avatar for c-work

Hi, I hope someone can help me with a problem that I am currently stuck on, basically I am trying to create a file archive utility which can archive 1 or more file each specified in a command line into a file. My problem which I am currently stuck on …

Member Avatar for krsna90
0
147
Member Avatar for kw42chan

Dear all, I m a newbie in C. When do the questions in "C Programming for Absolute Beginners" (MICHAEL VINE, 2008) When talked about structure programming, there is a question. Write A function that prints an ATM menu—it receives no parameters and returns no value. Void displaymenu() /********************* Function Prototypes …

Member Avatar for deceptikon
-1
256
Member Avatar for saurabh.mehta.33234

When I use void main in the code it compiles successfully but gives an runtime error on gcc compiler..But when void is replaced by int then it doesnot show any errors.What is the reason behind this behaviour?

Member Avatar for deceptikon
0
45
Member Avatar for srivardhanms

Hi, In openssl, X509_STORE_add_cert() would add a certificate to the list of trusted certificates in the ctx. What is the way to remove a certificate from this trusted store? Am not finding any function to remove the certificate. Can anyone of you suggest a way to remove the certificate from …

0
78
Member Avatar for kw42chan

Dear all, I am a newbie in C. Just come across function prototype. I have a task in write a function prototype for: * A function that finds the larger of two numbers and returns the result and i write the following. #include <stdio.h> /* Function Definition, I do not …

Member Avatar for kw42chan
0
409
Member Avatar for nitin1

i have an array of strings (2D array). i am taking input of strings and that strings can be same with strings which i have inputted before that string. so i want that i don't enter that string which is already being taken into array. so how can i do …

Member Avatar for deceptikon
0
129
Member Avatar for christodoulos14

hello i have some a problem with malloc, here is my code: int add(int m,int n) { int **pina, **pinb, **pinc; int c=m*n, i=0, j=0; pina=NULL; pinb=NULL; pinc=NULL; free(pina); free(pinb); free(pinc); pina = (int **) malloc (sizeof(int *) *c); pinb = (int **) malloc (c* sizeof(int *)); pinc = (int …

Member Avatar for christodoulos14
0
181
Member Avatar for Huxaifa

In our university following registration numbers are assigned to students 786-FBAS-BSSE-F12 Where 786 is student ID, FBAS is faculty, BSSE is degree program and F12 is Batch. Write a program that reads registration numbers of 20 students. Use array of structures for storing student information. Provide user with following menu …

Member Avatar for Moschops
0
146
Member Avatar for moroccanplaya

Task Your task is to write a file archive utility similar to that of the Unix tar program. This program will be a command line program (i.e. there will be no graphical user interface). The purpose of this file archive utility is to allow users and system administrators alike to …

Member Avatar for Dolby779
0
219
Member Avatar for tadas.bareikis

Hi I have written a program, it doesn't work and i can't figure out why. It does compile, but it doesn't run. The whole program: #include <stdio.h> #include <stdlib.h> #include <ctype.h> int main() { int a; int j; int c; int d; int dig; c = 0; int i; a …

Member Avatar for Moschops
0
167

The End.