15,552 Topics
| |
[QUOTE=letmec;107703]I'm working on TSR through C. i have writen dogens of them for dos, :rolleyes: but it works for dos only, can you tell me who to write TSR's for windows. Thankyou....[/QUOTE] I want to post the same question also. All I understand is: Windows (say Windows 98) runs under … | |
Hi, As said in the title, the program needs to accept only integer values.. It should not accept float point numbers or characters or spaces or integers mixed with characters .. I know it has to do something with the while statement but i cant figure it out .. Your … | |
Hi I've got a strange problem that i'm going to explain but before, here is my code: /!\ This is not my finished application /!\ [CODE]#include <windows.h> #include <stdlib.h> #include <stdio.h> #include <string.h> #include <conio.h> struct Date { short Jour; short Mois; short Annee; }; struct Ouvriers { char Genre; … | |
| guys how to slpit a date string ie....30/jully/2001 i want the following output 30 jully 2001 please help... |
i want to wrie a code which determines whether a given input is relocatable object file or executable file? i have knowledge about C .....but this task is totally new for me. can anyone please guide me? | |
i am trying to implement a simple keylogger... my code works fine and is able to detect simple keystrokes.... the problem that im experiencing is that whenever a key is pressed it remains pressed forever even after i release the key unless i press some key again...and if i try … | |
Hello, I'm making a scoreboard and I'm using multiplexing 7 segments. With a remote control I'm controlling the counting of the digits. I have two big problems with this. The first is that I can count just 2 times by sending b to the UDR. After that I have to … | |
You are to write a program to track the vehicles that are parked in and out of a parking lot. When the program runs, the user should be able to the total and available parking spaces. The program should also display the menu: [1] In [2] Out [3] View Parking … | |
Hey guys, so I'm trying to write a little program that will put together any number of strings passed to it into a single string and then print out that string backwards. I think I have everything correct but I keep getting a "Segmentation fault (core dumped)" error after compiling … | |
I have an assignment in which I need to rite an OpenGL program that displays a green square on a black background. Does anyone know a good free software I can download to run this. I'm mostly familiar with java, and since this is in C, I don't know where … | |
I have a txfile.txt file which has the following data: 3 2716 16253 7721 35149 972 2614 I am trying to read the first integer into a variable using this code: [code=c] #include <stdio.h> #include <stdlib.h> int main() { int num_cust[1]; int result; FILE *fp; if( (fp = fopen("tsfile.txt", "r")) … | |
Hey guys iam new in c and iam learning on my own, I have a task in book which is well complicated(at least for me) .(it want me to create the file , insert the text then copy text without vowels into a new file). I know i have long … | |
what to do if i want to execute some statements in a loop till the user enters any key? i did this earlier but have forgotten the logic... example:- while(1) { printf("abc"); /*i want this code infinitely, but as the user presses any particular key it should stop the execution*/ … | |
Hello all, I have a problem with a function I wrote. I wrote a main() that takes from current library a *.c file (that the user gives by the argv[1]) and make a copy of itself but without the comments and saves it as *.c1, so after this operation we … | |
Are constants, defined by using the keyword const , external linkage or internal linkage? Can constants be modified using pointers? What about constants defined using by #define? | |
Hello All, I am not sure why my algorithm is not working for this problem. I need to store space separated arguments in an array char* argBuffer[], so I can later make some system calls . The problem is that the last argument is writes over all indexes of the … | |
So heres the guidelines: Write a C program that simulates a 3-bit multiplexor. Your program should first read the 3 control inputs; then read the eight source inputs; then print the output of the multiplexor. When you read the control inputs, let the last input be the least significant bit. … | |
I'm new to C and I have a question I think it's not that complicated. I'm trying to write a code that creates strings like : File1,File2,File3, etc. Here is my code: [CODE]#include <stdio.h> #include <string.h> #include <stdlib.h> #include <string.h> int main(void){ char string1[80]="File"; char string2[80]=""; int number = 10; … | |
I've been set in a lab session at University the task of creating a program which can perform one of a variety of calculations, with it performing the one specified by the user, and with it looping back after every calculation however it is the looping which is causing me … | |
WARNING: I am a botanist, not a programmer. If you are offended by newbie questions, please jump to the next thread. I'm in the Environmental Horticulture at the University of Florida and I'm trying to build an online, multiple-entry key to help students identify the plant families. I have permission … | |
Hi. I am new in C programming. I am tasked to complete a program. The hardest part in programming is to understand the logic of a program. Please explain to how and why the algorithm works. I have commented the parts that i need know of/needs help in green. Your … | |
hello im new to linux programming and i am experiencing a bit of diffuclty with pthreads...basically the pthread_create() function in my code below i tend to pass an integer variable as the argument for my runner() function but i get a warning and an error..i have tried several ways of … | |
Hello all, I am third year student pursuing computer science engineering and I want to develop a software which can be coded in C and includes integrating it with database for data. I really need help for some ideas which are new(I need to develop something which is original or … | |
#define print_int(a) printf("%s : %d\n",#a,(a)) int y=10; print_int(y) i am taking a class and have been asked to explain why this is bad... So i guess stringifing #a is the problem. It does work, so why is it dangerous? | |
I'm having a lot of trouble getting my code to compile. It basically has this structure: [CODE]Headers: a.h, b.h, c.h CXX: a.cxx, b.cxx, c.xx[/CODE] And my main.cpp of course. The problem is that my classes link each other, ie. a uses something from class b and b uses something from … | |
[CODE]/*Simply change the path in initgraph(&gdriver, &gmode, "d:\\TC\\BGI"); e.g if your working directory is E write "E:\\TC\\BGI"*/ #include<graphics.h> #include<stdio.h> #include<conio.h> #include<math.h> #include<dos.h> int main() { float i,k,r; int gdriver = DETECT, gmode,c,j,l=57,m=56; initgraph(&gdriver, &gmode, "d:\\TC\\BGI"); printf("House constructed by Paritosh:"); printf("\nFor the visibility in different colors enter any integer: "); scanf("%d",&c); … | |
could someone explain to me why the compiler(gcc) outputs a warning that the control reaches the end of a non void function? [CODE] #include <stdio.h> #include "stack.h" #include "globals.h" #include "stack_interface.h" #define ERR_PUSH "Error in pushing symbol (character #%d).\n" #define ERR_POP "Error in popping symbol tp match character #%d.\n" #define … | |
[CODE]typedef struct electro { char name[20]; int access_number; char address[50]; float balance_due; }; electro account[10]; electro account[0].balance_due=$ 120.52; electro account[0].address[50]={Cane Gardens};[/CODE] Can someone tell em how to correct this piece of code. I'm using Codeblocks and it says it " expected an initializer before '.' " in the two last … | |
[CODE]#include<stdio.h> #include<string.h>\ struct name { char contact[20]; long int no; }; int main() { int i,check; char ch[20]; struct name cse2[10],*p; p=&cse2[10]; for(i=0;i<10;i++) { printf("Please enter contact name: "); scanf("%s",&(p+i)->contact[20]); printf("mobile no: "); scanf("%ld",&(p+i)->no); } printf("Please enter a contact name to find his\\her mobile no: "); gets(ch); for(i=0;i<10;i++) { check=strcmp(ch,(p+i)->contact[20]); … | |
Say you had a struct like this: [code] typedef struct{ int i; short s; unsigned char pad[2]; } test_t; [/code] What would be the point of adding the member pad as doesn't the compiler automatically do things like that? I saw a struct like this looking in some source code … |
The End.