199,114 Archived Topics
Remove Filter ![]() | |
Hi all, My problem is regarding to my last post about argument. that is solved but it create a new problem. The last data in debug_file is not written in output file. I think its because of looping in the argument.How to solve this? [code] int main(int argc, char* argv[]) … | |
Hi i need to change the random numbers in my output to random 'b''s that take up 2/3 of the array and random 'x''s to take up 1/3. Ive been at it for a few days and still have no clue on what to do. Heres my coding and output: … | |
We are asked to write a NASM program that will read a list of 10 2-digit integers, and output them in a column. At the base of the column, give the average value of the set of integers. | |
hey guys, i have to do this program and i'm having trouble with this certain part: Write a program that lets the user enter the loan amount and loan period in number of years and displays the monthly and total payments for each interest rate starting from 5% to 8%, … | |
Hey:) I am creating a project in java,but have been sick for the passed 3 weeks, so I am a bit stuck on how some of the code should look,and where it should be the details are that I am required to develope an application that will allow the user … | |
for my own satisfaction, im trying to make a program that does AES encryption, but ive run into a problem: i cant find an efficient way to us the s-box, and i would rather not have a switch statement with 256 cases. what could i do to do this effieciently. | |
Hi there, I'm am trying to write a recursive C++ function that writes the digits of a positive decimal integer in reverse order. [code=C++] #include "stdafx.h" #include <stdio.h> #include <iostream> #include <conio.h> #include <cstdlib> #include <math.h> #include <string> using std::string; using namespace std; int reverse_num (int number, int m) ; … | |
Is there difference b/w Javascript & JSP. are JSP is the abbreviation of Javascript. In my point of view Java is totally different from Javascript. There is slight confusion about Javascript &JSP. Can any one explain it | |
ive been trying to figure this out but i have no clue how to ive got a string thats a whole file and ive used find and replace but that only works on the 1st of the word if i have multiple of that word how could i replace them … | |
[code] //Date: 3/17/2010 import java.util.Random; public class Bingo { public static void main(String[] args) { Random bingo = new Random(); for (int i = 1; i <= 50; i++) { System.out.println("Card #" + i + "\n********"); System.out.println(); for (int j = 1; j <= 24; j++ ) { int bingoNum; … | |
I am trying to write some code to practice using methods. My goal is to get the user to input their weight. Then in the method I want to convert the earth weight to moon weight, which is earth weight / 6. I think I got it but I can … | |
Hi friends, I am developing a simple webcam accessing application, My aim to access one or more than a webcam over the Network or Internet, How to do.?? I am stuck.. :( Please Do help, | |
I am suppose to count the number of vowels in a user inputed string. I dont know what i am doing wrong it gives me one error? [CODE] #include <iostream> #include <string> using namespace std; int count_vowels(string str) { int count = 0; for (int i = 0; i < … | |
Hi, First time post here. I understand that you all like to have attempted code, but I just have a conceptual question. My task is to create a C program that takes in a user inputted string and counts the character frequency. I am given a skeleton file with the … | |
I am making my own CMS website and the body content is echoed onto the page however some of the page content is php code but the actual code is echoed out. How can i make it so that it works properly. Code: [CODE]<div id="form"> </div> <h1>Form</h1> <br /> <?php … | |
Hi, so I'm in the process of writing a music player with a GUI. I would like to be able to print a statement after I am done playing a song. I originally through I could just get away with getting the song's length and time.sleep'ing for that long. Since … | |
I have a textbox on my form. I type in some text, then I submit the form, and it seems that my script doesn't see the text in the input element and treats it like empty: [CODE] <?php $invname = $_POST['invname']; if($invname == '') {print "You have not entered the … | |
I am having problems filling an array of objects with a txt file. It seems to me that it should work, but I get all 0's printed out. Please help! I cannot write the rest of my code until I figure this out. Also I get this error message: "Exception … | |
I'm trying to figure out a way I can change this program so that I could have a semi-colon ; instead of \n to indicate the end of a command, like this: a ; b The command is: a The command is: b a The command is: a How can … | |
Hi, I have a written a program using multimap and its not giving me the results I am expecting. I have used pair in my program. There is some problem which I am unable to figure out. Perhaps I am using pair for the first time with multimap. Here is … | |
Here is the deal. I am writing a program in assembly that compresses and decompresses text based files. The user should be able to input a text file, and declare the name of what that file should be name when turned into a .drl file (just a random extension for … | |
Would like to know the cause of the error type or code Pls help | |
Hello I am learning asm at the moment. Can somone help me. I need to output the contents of a register to the screen. How would i do this. I can create hello worlds, outputting strings. How would i output other forms of data. Cant find this anywhere. | |
hey I'm making my own adventure text game and I need help. [CODE]def getEnergyAndMana(magicExp, energyExp, maxYourMana, bonus, energyLevel, bonus1): magicLevel = 0 if magicExp >= 0: magicLevel = 0 maxYourMana = 50 + bonus if magicExp >= 550: magicLevel = 1 maxYourMana = 100 + bonus if magicMax >= 1150: … | |
id been working on this for days now, maybe someone could help me figure this one, i have this items in listbox2, my database has a field for project, data directory, etc... if my first item in listbox2 equals to the field PROJECT in my database, i want to get … | |
ShoppingListItem.java [CODE=java] package problem2class; public class ShoppingListItem { private String name; private int numOfItems; private double price; public ShoppingListItem(String name, int quantity, double pricePerUnit) { this.name = name; numOfItems = quantity; price = pricePerUnit; } public String getName() { return name; } public void setName(String name) { this.name = name; … | |
I am searching for a script that retains both text and checkbox field values like the script at: [URL="http://www.dynamicdrive.com/dynamicindex16/formremember2.htm"]www.dynamicdrive.com/dynamicindex16/formremember2.htm[/URL] An ASP or Java script would work best. Thanks. | |
Hello!I have to check one txt file for simetrical words(like 1221 or abccba) and put these simetrical words into other file.End of word is ().,!? or space I have figured out how to find out if string is simetrical. [CODE] int main() { char s[100]; gets(s); int len=strlen(s); bool b=true; … | |
I thought I would let you's php gurus know that I am starting to come close to cracking the Sha1 algorithm. And surprisingly it is an easy one to crack. So I would recommend switching to something like the whirlpool algorithm. | |
Hi, I am now trying to extend my program to allow the events in the file to be sorted by any of the fields (date, time, title, description, location and to have an optional list of attendees) Whether the attendees are present or not I need to allow either an … | |
Can someone tell me why I cant get anything to echo properly with this? <?php session_start(); $_SESSION['company'] = $_POST['company']; $_SESSION['firstName'] = $_POST['firstName']; $_SESSION['lastName'] = $_POST['lastName']; $_SESSION['phone'] = $_POST['phone']; $_SESSION['email'] = $_POST['email']; ?> ... This is on one page <h2><a href="Conference_Start.php">Personal Information</a></h2> <p>Company Name: <?php echo $_SESSION['company'] ?> <br />First Name: … | |
This is what i have for code this far, i need help trying to keep score here. Any help would be well appreciated thanks [CODE] int sum = 0, teamScore, numPoints, score1 = 0, score2 = 0; while (teamScore != -999) { cout << "Did team 1 or team 2 … | |
Hello I am new to python...I met with this simple problem [CODE] def search(path,filename,extension): name=' ' listdir=os.listdir(path) print listdir flname=filename+'.'+extension i=0 match='' while(i<len(listdir)): if(listdir[i]==flname): match='YES' print 'got the match' break i=i+1 if(match=='YES'): assign(filename) else: name = filename+'.'+extension print 'the filename is',name return name lets_text=search(path,filename,extension) print 'the name we gt is',lets_text … | |
Hello, I am very new to .asp and I have been tasked with updating a dropdown box in one of our web applications to include a "blank" field at the top of the dropdown box so that if a matching result isn't found, it will default to a blank value … | |
Hey.. =) I am making a program and i need to use: [CODE=c#]using System.Data.ADO[/CODE] But it won't work? Anybody know what i can do? | |
I am a final year university student quickly nearing my project deadline. My project is to write an artificial intelligence program for a robot to find its way through a maze. I have been using a Lego Mindstorms Robot and the NXC (Not eXactly C) programming language to write and … | |
[code] //Date: 3/16/2010 import javax.swing.*; class PizzaChoice { public static void main(String[] args) throws Exception { char[] whatSize = { 'S', 'M', 'L', 'X'}; char size; double[] sizePrice = {6.99, 8.99, 12.50, 15.00}; int s; System.out.println("What size do you want?"); size = Character.toUpperCase((char)System.in.read()); for (s = 0; s < whatSize.length; … | |
I have a form that "activates" the submit button; switching a greyed out version that does nothing for the working one, when all the fields are correctly filled in. The problem arises in IE 7 when the submit button is supposed to be activated. The greyed one disappears, but the … | |
I am trying to insert data from a form into a SQL Server 2005 database. The only code examples I can find are for Access databases. I am having a problem at the execute command. I have tried three different ways to execute but the page goes to an error … | |
Okay, so what I'm trying to do is to write a program that reads several TGA images and bunch them together into one bin-file for later use. I got this code from [URL="http://nehe.gamedev.net"]NeHe OpenGL[/URL], Tutorial 24, and it is what I use to load my images: [CODE=C++] bool loadTGA(char *path, … | |
Ok so i am going a whack a mole game. What method i did was that i used a picture box (I couldn’t use the button) to display a mole on the screen. So when the timer starts the picMole.visible= true and when clicked score is changed mole becomes invisible … | |
Hi, I'm super new to Java, and am desperately in need of some help. I'm making a little java desktop application where I basically have a grid of 4 JButtons ( 2 x 2 grid), and I need the background colour of individual JButtons to change, and after one second, … | |
[code] Private sub btnCompute_click () handles btnCompute.click Dim Total, labor, customer As String labor = cdbl(txthour.text * 35) parts = cdbl(txtpart.text + 5%) Total = labor + parts customer = txtname.text lstResult.Items.add.clear() lstResult.Items.add("customer" & customer) lstResult.Items.add("Labor cost" & Labor) lstResult.Items.add("Parts Cost" & Parts) lstResult.Items.add(" Total Cost" & Total) end sub … | |
Hi there, I have a problem in that my derived concrete classes are loosing the data members which are part of my derived classes. I have wrote a simple program to show the problem. [B]GrandParent.h :[/B] [code=c++] #ifndef GRANDPARENT_H #define GRANDPARENT_H using namespace std; #include <string> /******************************************************** Abstract base class … | |
So here's the rundown. I have a base class, I want to put a clickHandler in it because all of my subclasses will need it, but they will all execute different code when it is triggered. My question is, how can i have a clickHandler in my base class and … | |
I am unable to open a child form as a modal form. Here is my scenario I have a MainForm which is a toplevel form. Inside the MainForm I have a Toolbar Form which is a child. From the Toolbar Form I call another child form. From that child form … | |
Hey I was writing programs in C using turbo C in dos box(vista)....however when i try to compile any program, I get the error: "Unable to include file "header file" I checked but and all the files are where they should be. Please help. | |
Hi, does anyone know or has any idea how to import values from a table and assign it to a variable? For example: Ambient Temperatures| 30 40 50 Corresponding factors |0.9 0.7 0.6 (note the table is in excel format and much larger) [CODE]double At,Ca; cout<<"Enter Value for Ambient temperature"; … | |
Hello. I have an issue with a game I am programming for my c++ project which I am hoping one of you kind souls can help me solve... I consider myself an intermediate beginner in c++. I am coding a space shoot-em-up in c++ with a proprietary graphics library provided … | |
Team - Could someone please tell me I haven't lost my mind? I have done relationships in the past but now they don't seem to work. Have I gone dumb? Creating a winform, using VS2008, sqlexpress & vb.net. My dataset looks like this: -------------------------------------------- Table 1 - BranchInformation BranchID - … |
The End.