15,552 Topics
| |
hi? i'm in need of help.. our instructor in computer programming asked us to make a program..mine is a program that will ask the user to input how many sides of polygon she/he wants..minimum of 3 and maximum of 10..and the output should be the polygon with the user's inputted … | |
OK, here's my sample code. The problem is indicated with [PROBLEM] at the starting of the code line. I'm getting a compilation error saying that: 706 C:\Users\user\Desktop\Project.cpp `reg_num' has not been declared 706 C:\Users\user\Desktop\Project.cpp request for member of non-aggregate type before ',' token and its saying this for all my … | |
hello there, I am working on a small c program that automatically detects whether the input given is a decimal number or a binary number and coverts accordingly. what is the best way to convert a binary number to a decimal number and a decimal number to a binary number. … | |
[FONT=Lucida Console][COLOR=Blue]is there any function that helps to sort an array of strings alphabeticly i need to sort an array alphabeticly which contains names of students thx 4 yr help matika :cool: [/COLOR][/FONT] | |
Hi basically i dont have time to do this coursework , due to overload of work .. it probably take like an hour for some1 who knows what they are doing .. ill pay like 15-20 quid ? | |
hello... i want to separate string like "!string" i need to put the "string" to some char*... i did char firstWord[10]; sscanf(text,"!%s",firstWord); why its not woking? and how to make it work? i try to search, but nada.... | |
Hey.. i want to make a string from a text file.. then i want to compare this string with another to see if they are the same... any help?? /*I'm a beginner*/ | |
fscanf is a C function designed to read character by character from a file to the system how we can use scanf programmatically to read till first white space ???? :) :) | |
Hi, The problem I'm having is killing a process without knowing it process ID. What I have right now is a client-server communication using FIFOs, the server is running in the background and the client is running in the foreground. What I want to do is when the client quit, … | |
Calendar Program [code]#include<conio.h> int day(int m1,int y1) { int d; if(m1==1 || m1==3 || m1==5 || m1==7 || m1==8 || m1==10 || m1==12) d=31; else if(m1==4 || m1==6 || m1==9 || m1==11) d=30; else if((y1%100!=0 && y1%4==0) || y1%400==0) d=29; else d=28; return d; } void main() { long unsigned … | |
hi, I cannot figure out the programme code for the following problem: Write aq programe code for printing all the combinations of the numbers 1,2&3. I would be gratefull if you can help me out with this. Thank you. | |
This has been working fine on my system, but refuses to compile on a server that I've uploaded it to. printf("Press <ENTER> to Continue\n\n"); while(getch() != 0x0d); The error message that I get is: undefined reference to 'getch' Any idea how to define getch and get this to compile? | |
Hello everyone, Firstly i'll like to introduce myself to the forum. HEy... Ya my need is tat i need a super simple ebook(FREE) on C programming and covering advanced aspects of C like C - linked list , c-graphics and C-BITS... help! /************************************************** **************************************************/ | |
I want the remainder of all the numbers inside the loop except the number which i assigned for variable [B]a[/B] for example , if i entered number [B]5[/B] for [B]a[/B], the loop is 5 4 3 2 1. i want my program to take remainder of all these values except … | |
Hi, Please some one clarify what does the below snippets mean and the compiler assumptions. which one is the correct one to use, what is the problem with others. [CODE] main() { } [/CODE] [CODE] void main() { } [/CODE] [CODE] int main() { } [/CODE] [CODE] int main() { … | |
hi i have a program here the 15 puzzle my problem is that im having a hard time makeing a random function the right way and also thinking of a way to make so that the program will not go out of the bounderies here my code [CODE]#include <stdio.h> void … | |
Any idea why this loop repeats regardless of the input? What I have there does correctly assign the proper values to month, day, and year, but the input prompt is repeated no matter what is input. Obviously I would like it to repeat if an impossible day < 1 or … | |
hi, i have a very simple problem with my program and just need a push in the right direction and will be much appreciative of your help. i have a bucket sort program which works fine. well i say fine, its fine when it is sorting the numbers initialised at … | |
i don't recommend atoi() or atol(). this does not handle invalid strings (non-integer strings) very well at all. for instance, if you try [code]value = atoi("CowAndChicken");[/code]the result will be zero (value = 0) and if you try [code]value = atoi("0");[/code]the result will also be zero (value = 0) strtol() avoids … | |
Hiii all i hav i little problem i wanna insert a char into an another char and add some other chars .. :D For example : I have the char A = "HE"; i wanna have in B ="HELLO Everybody"; i was doing this in php : [CODE] $string=$A."LLO Everybody";[/CODE] … | |
[CODE] #include <stdio.h> #include <stdlib.h> int det(int); int minor(int); int main() { int mat[10][10],dim,a,b; printf("Please enter an integer for matrix dimensions(1-10):"); scanf("%d",&dim); for (a=0;a<=dim-1;a++) { for (b=0;b<=dim-1;b++) { mat[a][b]=rand()%10+1; printf(" %d",mat[a][b]); } printf("\n\n"); } printf("Determinant for the matrix is: %d",det(mat)); return 0; } int det(int mat[10][10]) { int a,b,temp,length; length=0; … | |
How is it that a string, or specifically a part of a string, can be isolated and put into its own integer variable? For example, a user is asked to input a date, such as 12/31/2000, which is saved as a string. How can the "12" the "31" and the … | |
I've created a software and i want to sell it, how may I proceed | |
Okay, I think I know the problem, but I don't know how to solve it. I want to write a binary file with raw bytes. Windows appears to interpret 10 as ASCII 10 and it does its thing where it interprets 10 as '\n' and decides to change that to … | |
Hi there! I am working on a simple text based console application for a game of battleship. I am not really looking for a raw code just ideas on where to go next with my code. Some things i would like to put in it that I am flat out … | |
please help me.. i dunno how to make my project in C/C++. it's about binary trees but we'll use names instead of numbers or single chars then the traversals.. PLEASE... thanks! | |
Hello im working on a C program that counts the number of tabs, blanks and newlines. Here is my code: [CODE] #include <stdio.h> #define MAXLENGTH 500 /* This program accepts a string as input. * It should then count blanks, tabs and newlines. * It should print out the number … | |
Ive been trying to figure this out all day but have been unable to make as progress so I was wondering if anyone here could help me out. Im making a program that allows the user to add a name, update the current name list , remove a name from … | |
hello every body >> i wana help to answer the question in the atteched file . | |
Can anyone explain whats wrong with this program why this is not working. [CODE] void main(void) { long a,b=1; clrscr (); printf ("Enter number to calculate its factorial:"); scanf ("%ld",&a); if (a=0,1) printf ("You entered 0 or 1"); else for (a=a;a>0;a--) { b*=a; } printf ("Answer is %ld",b); getch (); … |
The End.