132,726 Archived Topics
Remove Filter ![]() | |
hey guys heres a program thats suppose to assign a letter grade to a given percentage on an exam and i just keep gettin the same three erros at the bottom saying i have undeclatred indentifiers but i dont see how so any help would be very much appreciated [code] … Software Development c++ | |
I'm working on learning how to use regular expressions, and have found a conversion that has me stuck. Given the statements: [quote] 1. pi=3.14 and pie 2. pie and pi=3.14 [/quote] How do I match pi and turn it in to 3.14 without also catching pie? This is user input, … Software Development perl | |
i have to make a minesweeper game for class, 3d none the less using microsoft visual c++. i have created my dynamic class. there needs to be a node class and a grid class. i have no clue how to do it. if you can help please help me, its … Software Development c++ visual-basic | |
All I'm trying to do is write a very simple loop program in C to enter the ages of four sprogs between 5 and 7. To display their total and average age using do, while and if statements. I also need to display an error message if an invalid number … Software Development c | |
I have a basic question with a for loop statement where I have a function thats creating input nodes inside my animation program. The name thats assigned to the input that the function creates is "InputNum" . How do I tack on the value of i to the end of … Software Development c | |
this is a progarm i have created to calculate srudent grades given the three grades. the computer then works out te average and assigns a grade depending if average is more than 50. the program stops after giving the average of the three grades and doesnt output whether pass of … Software Development c++ | |
Hi. I recently started learning VB.net in school, and now as a project, im making a simple sliding shooter. (You know, a ship that you control up or down, and you shoot at enemies that fly towards you) Thing is, I just cant figure out a good way to make … Software Development vb.net | |
Alright, so far, what I think the problem begins with is not having a full understanding of syntax, and tabs versus spaces. I have my tab set to four spaces. When I run the following code, the Python GUI (the black ms-dos looking thing, right?) flashes for only a few … Software Development gui open-source python | |
I am doing my homework and I have to create a payroll program that will loop until the user enters "stop" as the the employee's name. I also have to make the program say that only positive numbers are accepted in the event of the user entering a negative number. … Software Development java | |
Hello you all. I am an MA student in Creative Music Technology and currently trying to write a little game based on voice recognition. I downloaded the speech SDK 5.1 from Microsoft and had a look at the example code. Evertime I hit "run" I am prompted with: "Runtime Error … Software Development visual-basic | |
Hi, A simple question I think. I want to create a function that updates variables if a certain condition is met. For example def main(): c=d=e=0 if c[1] == 0: c=c+1 d=d+1 e=e+1 I want to create a function that adds the 1 to c,d,e automatically. def BB(c,d,e) Add 1 … Software Development python | |
![]() | hey... I wasn't able to find much information on these class methods other than __init__ ... could you explain what these (and maybe some others) do or perhaps just give me a link to a page that explains them: def __repr__ def __str__ def __cmp__ Software Development python ![]() |
Can anyone help me with this project, I cannot figure it out. Enter characters one by one until a predetermined “sentinel” or the maximum number of characters is entered. The maximum [B]MUST[/B] be less than 96. The sentinel character can be any character other than an italic alpha or, space … Software Development c++ | |
Hi All, This is my first posting :) I urgently need some help!! I am trying to call a perl script from another and capture the exit status (whether successful or not). How should I go about it? Please help.... Thanks in advance, Bucchi Software Development perl | |
Hi, I am doing a part time degree and need some help to finish off some code for my first assignment in C++. I have written a program which checks some inputted int's and strings, validates them and outputs the result. The last thing I need to do to finish … Software Development c++ | |
[B]Hey i have been working C, But i need to do a Convolution progrm in C, So pls advice on this matter How to initialize..[/B] Software Development c | |
does anyone know how I can write to a xls that puts each number in different cells? for example, [CODE]vector<int> nums; nums.push_back(1); nums.push_back(2); nums.push_back(3); ofstream myfile; myfile.open("C:/example.xls") myfile << nums[1] << " " << nums[2] << " " nums[3] << endl; myfile.close()[/CODE] how do i put three numbers in different … Software Development c | |
i need to write a program that- allow the user to enter the number of students-allow the user to enter each mark-calculate the frequency for each mark-the interval that exists between identical marksthis is what i have donei want to know if there is a different way of doing it#include#define … Software Development c | |
[code]/* a program to find all the permutations of an input string pointers are not allowed*/ #include <stdio.h> #include <string.h> #include <conio.h> void main() { clrscr(); int num =0; char buff[20] ; printf("Enter the string\n"); scanf("%s",buff); int len = strlen(buff); printf("%s\n",buff); for(int i=0;i<len;i++) { for(int j=1;j<len;j++) { for(int k=j+1;k<len;k++) { … Software Development c | |
Hi there, im a c++ noobie. I have a class called node. Node has a data member id. When i try and access id in the obect named f outside of main visual studio 2003 gives me the errors: : error C2065: 'f' : undeclared identifier error C2228: left of … Software Development c++ visual-studio | |
i need to write a program that- allow the user to enter the number of students-allow the user to enter each mark-calculate the frequency for each mark-the interval that exists between identical marksthis is what i have donei want to know if there is a different way of doing it … Software Development c | |
the function first search a word from the linked list. if found it then increment the numWords (number of words in listfor that word) and if not found it shoud create a new node for the word. the code is: [CODE]void AddWords( char text[30]) { check=head; while (check!=NULL) { if … Software Development c linked-list | |
Hi, I am new in shell script and I road this script, but it does not give the output I want. The output show look like this: Instance on [COLOR=Red]fac1[/COLOR] [COLOR=Red]inst1 [/COLOR]instance Instance on [COLOR=Red]fac2 inst2[/COLOR] instance Instance on [COLOR=Red]fac3[/COLOR] [COLOR=Red]inst3[/COLOR] instance Here is the script: [code]INSTID="inst1 inst2 inst3" FANCID="fac1 … Software Development shell-scripting | |
Alright, I cannot get the getline function to work. I have iostream included, using namespace std, and here is the syntax I have down: [inlinecode]cin.getline(playerOne, 21);[/inlinecode] with playerOne declared previously as a string, and I want its max input to be 20 characters. What's going on here? It's not working … | |
Ok our teacher gave us a .h and .cpp file for a class called "JarType" and our assignment is to overload some of the math operators. Now I know how to overload operators if I'm adding two JarTypes together. What I'm having a problem with is overloading when I have … Software Development c++ first-post | |
How would you change the same member of many objects of the same class (or structure if possible)? [CODE]struct point { float x, y, z; } point a, b, c; a.x += 20; // b.x += 20; // now how would i do this in one statement? c.x += 20; … Software Development c++ | |
Hey guys. Ive been working with fstream for about 2 hours and i give up. My problem is I have a text file with an unknown number of rows. Each row has a known number of items. i cant figure out how to read the elements in each row. after … Software Development c++ | |
I've knocked up this rubiks cube, its not fully complete. If you click and drag on the space, you can rotate the cube in any axis. If you click any of the 12 rotation buttons, you can rotate the cube, note that you can still rotate the cube with mouse, … Software Development java | |
![]() | I searched the forum and couldn't find anything on this, so I guses I'll give this tiny topic its own thread. What's the point of creating a main() function and calling it at the end of your program? Are there advantages to this method in comparison to just writing the … Software Development python |
![]() | say you have a list: [php] list = [1,a,2,b,3,c,4,d,5,e,6,f,7,g,8,h,9,i,10,j,11,k,12,l,13] [/php] What's the easiest loop set up if I want to store each number (every other slot) into another list? The above list is actually text from a file read and then split with "1 a" and such on each line … Software Development python |
Hi When i place this in my script import time.sleep (2) i would like my script to wait for 2 seconds then continue. But when i run it the left bracket is highlighted in red then when iremove the left bracket as i assume that is not supposed to be … Software Development python | |
Write a program that accepts a number and produces a pattern as shown in the following sample outputs. Line = 3 *.* .* * Line = 8 .*.*.*.* *.*.*.* .*.*.* *.*.* .*.* *.* .* i've just learnt to use the setw() command..... but how do you fill up the alternate … | |
I installed Ubuntu Linux this morning and got java jdk 1.5.0_09 installed, along with Eclipse, and then I imported a project I've been working on into the Eclipse workbench. All configuration is fine, as far as I can say. My problem: The program I am working on uses the Enum. … | |
hi, i need to write a c++ program that takes input of a expression like say y = 5 + 2b; and gives out the output y = 5 + 2b it uses linked lists and the expression can be composed of integers, variables and operators. the encoding of tokens … Software Development c++ ![]() | |
Hello, I need to write a program that runs along with an emulator. The goal of my program is to intercept certain keystrokes before the emulator gets them, and then send the emulator back some different keystrokes. I want the program to use as few CPU resources as possible, as … Software Development c ![]() | |
We cannot have static friend function............ because 1.since static member functions can access only static data members...where as friend function can access all the members. 2.Friend function also require an object to access the members...where as static member functions can not. 3. Another thing ....since friend functions are non-member functions....and … Software Development c | |
Hello, i'm trying to write in the main program a linked list of namesfractions, and integres. i don't know if anyone can help me in this. i attached the fraction class and the implementationUsing the linked list class we derived in class, and the following functionality:[LIST] [*]A print function (you … Software Development c++ linked-list ![]() | |
Hi Im looking for a time delay code so my script runs to certain line waits for the time specified then continues.Ive found some but they seem to long and complicated. any ideas or links, books ect... Many Thanks HlA91 STAY COOL AND DONT GET STRESSED!:cool: Software Development python ![]() | |
Hi, I have the following code: import string def main(): rank=[] suit=[] fname=string.split(open('H:\card.txt').read()) for line in fname: rank.append(line) print rank The file (card.txt) is: 2 h 3 h ... How's the easiest was to get the 2 into rank and the h equal hearts Ultimately i need it to print: … Software Development python | |
So a kid in my class wanted more of a challenge...the professor gave us one...and I have no idea on this problem. Here's the instructions: Darts scorer. Write a program that draws a darts target and allows the user to click on the target to represent darts hitting the target. … Software Development python | |
I recently downloaded Py2exe to make my python2.4 programs executable in motive of possible distribution. I looked online, and most of them tell me I need to use my ms-dos prompt, or command prompt. If these are two different things on my Windows 98 O.S., i cannot find command prompt. … Software Development python | |
Hi, If the following def shows if a deck is empty, how do I change it to show the number of cards left??? def isEmpty(self): return (len(self.cards) == 0) I was thinking just taking the ==0 should work, by returning number of cards. macca1111 Software Development python | |
Hi I was goinf through the GTK code and saw that GTK code uses pointer for structs and not normal instances of the same structs... why could this be so? My take is that they wanted to use just one variable name and they can easily initialise the pointer to … Software Development c | |
[code] #include <cmath> #include <iostream> using namespace std; //Function prototypes void getPrice (float&); void getInterestRate (float&, float&, float&); void getDownPayment ( float&); void gettradeIn (float&); void calcmonPayment (float, float, float, float, float, float&); int main() { // Input variables float price; float downPayment; float tradeIn; float loanAmt; float annualIntRate; float … Software Development c++ | |
i have this line of code and want to compare the word from the linked list with the one supplied by user. the code is: [CODE] if (strcmp(p->word,word)==0)[/CODE] and i am having this error: [COLOR="Red"]passing `char' to argument 2 of `strcmp(const char *, const char *)' lacks a cast[/COLOR] Software Development c linked-list | |
Hi Everybody: I've attempted at getting Java Sun certified twice (failing both times). My first score was a 22% and my second score was a 44% (big improvement :D ). I was wondering if anybody had any help or tips for taking the exam. I really want to pass next … Software Development java |
The End.