199,114 Archived Topics
Remove Filter ![]() | |
![]() | [CODE] #include <iostream.h> #include <stdlib.h> template < class ItemType > class stack { private : int top; int maxStk; ItemType *items; public : stack(); stack(int max); int isEmpty(); int isFull(); void push(ItemType newItm); int Pop(ItemType &Itm); }; template <class ItemType> stack <ItemType>::stack(){ top=-1; maxStk=500; items=new ItemType[500]; } template <class ItemType> … ![]() |
Hi all, I'm working on a problem where I have to store,retrieve, update the data from some temporary variables (for e.g. array) The scenario is as follows. Assume I have a datagridview with n number of rows and 3 columns for e.g. [CODE] Id name class 1 ff 2 2 … | |
Hey guys. I just learn about magic numbers today. I am trying to make a program that uses fstream along with magic numbers to tell what a file is. Example the magic numbers for jpg are ff d8 ff e0. How do i check a file to see if its … | |
Hello i am new to java and o have to write a program that determines the number of prime numbers less than N which is given by the user, but i have no clue where to start | |
I get this error, [CODE]Exception in thread "main" java.io.IOException: Cannot run program "java -jar C:\Users\Jack\testFile.jar\" (in directory "\"): CreateProcess error=2, The system cannot find the file specified at java.lang.ProcessBuilder.start(Unknown Source) at testProject.Main.main(Main.java:15) Caused by: java.io.IOException: CreateProcess error=2, The system cannot find the file specified at java.lang.ProcessImpl.create(Native Method) at java.lang.ProcessImpl.<init>(Unknown Source) … | |
i have this html code: [CODE]<table border="0" width="24%" cellspacing="0" cellpadding="0"> <tr> <td width="62"></td> </tr> <tr> <td width="62"><span>Country<span>:</span></span></td> <td><select name="country" class="cbbody"> <option selected>Select a Country</option> <option value="CA">Canada</option> <option value="US">United States</option> <option>--------------------------------</option> <option value="FR">france</option> <option value="ES">Spain</option> <option value="DE">Germany</option> <option value="IT">Italy</option> </select></td> </tr> </td> <tr> <td width="62">State<span>:</span></td> <td><select name="state" class="cbbody"> <option value selected>Select … | |
Hello, I'm trying to calculate the center of a DIV element. But it doesn't seem to be working, I don't quite get what to do with the calculations.. Here's my code: [code] <html> <head> <script src="http://code.jquery.com/jquery-latest.js"></script> <style type="text/css"> body { background-color: #cccccc; } .rectangle { width: 400px; height: 100px; border-style:solid; … | |
![]() | Hi all, been dipping my toe into OOP and am getting on OK, but I'm hitting a bit of a wall with a current project. classes: db (a PDO extended class) User Timetable The db is just a few shorthand ways of running PDO The User is just for handling … ![]() |
Hi could you help me ? how to implement 2 stacks with a queue in data structurs ? | |
[COLOR="Green"]Hi all Pls tell me how i can read a data from EXCEL file and copy it to a text file using c++ program.I dont want to do it as manually .(Its for an extended application for software).I want to read the data from perticular cell to the end of … | |
Hi guys, I have already posted a thread regarding this but no one has ever shed a light upon it. I want a program that searches for files (.docx, exe, ppt, txt) from all folders. Is this possible i the first place? If yes, then how? | |
Okey I am making a simple chess program as an assignment and I ran into a few problems I coded a file called ChessPiece which is the Base class of all the chess Piece eg King ,Queen and etc... We have to create a interface class call ChessPaint that draw … | |
hello all where is the directory to place file below import com.toedter.calendar.JDateChooser; is it correct if the extracted folders and files be placed in folder c:\com\toedter\calendar\JDateChooser ? or because i place my source file in c:\java\src do i have to place the extracted folders and files in c:\java\src\com\toedter\calendar\JDateChooser ? I … | |
can somebody help me with switch statement. [CODE] import java.util.Stack; import java.awt.*; import java.awt.event.*; import javax.swing.*; import java.math.*; import java.util.Vector; public class Ahsan extends JFrame{ Stack s = new Stack(); private JFrame f; private JPanel p1,p2; private final int ADD = 1; private final int SUBTRACT = 2; // declare … | |
Hello brows,I'd like a little help. I'm making a web online game,then in the Map system. I need get coords of players that is around. Get in Database something like that: [CODE] <?php $result = mysql_query("select * from mapa where x_coord > '5' AND x_coord < '10'"); while($row = mysql_fetch_array($result)) … ![]() | |
Can i change the array's rows length after i define it as constant or any other way? Can you under my code or explanation? [CODE]#include<stdio.h> #define CLASS_SIZE 20 //First define the array rows's length void main() { double gpa, average, highest, lowest; int student, rows, i, j; char grade[CLASS_SIZE][5]; //Wish … | |
Is it Mother Date and Father Time? Any way, getting all the different date and time displays working can be imperturbably perplexing at times. You take a look at it in this Windows Console Application. | |
Hello Everyone , I have developed a windows application with mysql database server. i have installed it to client machine also. Now,the problem comes when i restart mysql server or server computer. After i restart server,client application can not able connect to server . if i disable network and enable … | |
[code] template<typename U, typename T, typename binary_functor> struct template_param_swap { binary_functor<U, T> func1; #1 binary_functor<T, U> fun2; #2 }; [/code] CH3 of modern c++ design may solve this, but I am not a template wizard and don't have the ability to make it yet. template template parameter could make #1 … | |
Hi guys! Pretty easy question below From the code below 'data' is made by a column of numbers, let's say 12 numbers (see below) 56.71739 56.67950 56.65762 56.63320 56.61648 56.60323 56.63215 56.74365 56.98378 57.34681 57.78903 58.27959 [CODE]def block_generator(): with open ('test', 'r') as lines: data = lines.readlines ()[5::] for line … | |
First i create simple claculator.but now I am trying to change it to RPN calculator by using stack.Can some one help me((especially where to use pop method) because I don't know alot about stack.here is my codes so far. import java.util.Stack; import java.awt.*; import java.awt.event.*; import javax.swing.*; import javax.swing.event.*; import … | |
Trying to make a short to do list. show item to do-->click who you are $who and $item sends to top to show that item no longer there, but the rest are [CODE] <? echo "Here is the list of things that need to be done!"; echo "<form>"; while($row3 = … ![]() | |
I have this assignment to do. Its been about a year since I messed with c++ and I've been refreshing my brain on the subject. The assignment is this : Your assignment is to write a program for a computer dating service. Each client gives you his or her name, … ![]() | |
Guys I want to know to skip error massages like the JIT error messages during run-time. What I want in the program is that instead of the JIT popping out whenever an error occurs, I want to generate a msgbox instead of that JIT. Can anyone please help me, thanks... | |
This may be a rather simple thing to answer, but I am no programming expert. Let me explain my problem in detail: for this homework assignment I need to open up a file with simple text in it, format it so that each line is reduced to a certain number … | |
Is PHP using to develop BLOg based that is CMS site or not? please reply... | |
Hey i am a beginner in programming I typed the following program on my own But there are a lot of errors it it Please help me find them [CODE] #include<IOSTREAM.h> main() { int a,b,c,x; cout<<"Enter three values - \nA,B,c."; cout<<"A-"; cin>>a; cout<<"B-"; cin>>b; cout<<"c-"; cin>>c; if (a>b) x=1 else … | |
Hello, if i want the computer to guess a number between 1 - 100 i'll do in java [CODE] int min = 1; int max = 100; [/CODE] I have already create a random number for the computer. so the first random number the computer will choose is 49 as … | |
I need someone to please advice me, which one is better in designing a website, dreamweaver or the CMS(Content management system.) Thanks for your usual contribution. | |
Hi all With the following SQL " Dim Query As String = "UPDATE JobName_tbl SET [JobDate]=@NewDATE, JobAddress=@Newaddress Where JobID=@ID" nothing happens nothing gets updated nor do I get an error. But as soon as I remove the [JobDate]=@NewDATE, it works fine. Hope someone can help me with this situation. Here … | |
Im looking for any Windows Application written in Assembly, just 1 form with 1 button :) | |
Hi There experts... i am hoping that someone will be able to help me with a problem... I have the following vba code.. some of you that are clued up with vba will know... it is a code i got from the net that allows me to choose dates before … | |
hey guys i am developing a game... in which when i press a button it has to change its color... so , i created button, used action listener to it... [CODE] if(ae.getActionCommand().equals("b1")) // here b1 is the button { b1.setBackground(Color.black); frame.invalidate(); frame.validate(); System.out.println("button b1 pressed...!!!"); } [/CODE] i also used … ![]() | |
I have this project that I'm working on for my class, but I'm getting stuck with infinite loops and I'm not really sure what's wrong. I'm supposed to assume that at time 0, the ball is at height 0 and the velocity is input by the user. After each second … ![]() | |
Hey guys. I need help with a program I'm trying to write. I need to read scores from an ASCII file and display them. I also need to display an error message for any score that falls outside of the range of 0 to 100. And after doing that, I … | |
Hey everyone, I am in an introduction to programming course, and I am tryin to solve the following problem using C#. I know that I am to use arrays, however I am a little lost and was hoping that somebody could give me some assistance. [ATTACH]20610[/ATTACH] Here is the code … | |
Hi All, I am trying to do a search on a index/row number taken from a dataview i.e. I enter 379437 in the input box which I know has a index/row number of 6. Now when I replace the Rows(index) with a Rows(6) I get the results that I want. … | |
I'm not sure if my title makes sense, but I have an assignment and need some guidance on how to approach this. It's an Accounts Receivable program for ABC Hardware Company. I have a Master file with cust numbers, cust name and balance due. I also have a Transaction file … | |
This is homework. I was writing a bash script that accepts a list of group names on the command line and produces a group report detailing the group id and the number of group members identified in /etc/passwd for each group. Output will look like: Group Report Group GID Count … | |
Hi guys i have a problem that i have a text file which contains very long text like : welcome to all, how are you doing, etc.. so i need to cut the text till each comma and put it in a separate file like i want to pu [welcome … | |
I have searched to try to find out what is going on and I can't seem to figure it out. I am trying to follow an online tutorial for a simple rating system and am having trouble. here is the code [CODE]<?php include 'connect.php' $id = $_GET['id']; ?> <form action="rate.php" … | |
Help, I have a big probem. I wanto to read data from an mysql table and then write this data into a form so that the user can update this data. The code could seem somethin like this, but it doesn't work [code] <?php include 'complete.php'; $user_name = "exa"; $password … | |
convertHex changes all occurrences of %XX (XX are exactly two hexadecimal digits) to ascii characters. Returns the number of replacements made. Here are the rules: Except when defining your character arrays, you must use pointer notation for all c-string manipulation--no []'s allowed. You may use any function from the cctype … | |
I am working on a python version of the game Lingo. Here are the rules: [I]"Suppose the secret word is bones. Suppose you guess the word books. The computer will mark your guess as [b][o](o)k[s], where [b], [o], and [s] are letters that are in the correct position in the … | |
Pals, I love this site with a passion. Again now i need to know how i can relate different tables together using SQL database with different field. Thank you for your responses. | |
Hello everyone. I am trying to pull data from a file and show it on the screen. There is a condition in the file that says if it is a "payment" or "order". A "P" and an "O" in the first column. My output becomes an infinite loop. I have … | |
Hi guys, I am writing some query from winforms. I am getting error with the following query: [CODE] string query = "Select [Doctor Name], Day, DateTime, Med_Sur from Doc_Pat_App where (lower([Patient Name])= '" + name + "') and (DateTime >= GetDate()))";[/CODE] I know that there is no mistake till lower() … | |
I was using getline() function and it was getting skipped. I searched through the forum and found the tutorial on how to flush the input stream but there is one thing that is still unclear to me : getline() uses newline character as a delimiter. So when a '\n' is … | |
i have three texts namely [B]price[/B],[B]quantity[/B] and [B]total[/B]. i want the value of [B]total[/B] to change with change in [B]quantity[/B] i.e [B]total[/B]=[B]price[/B]*[B]quantity[/B]. each time the value of quanity change, the function multiplies it with price and displays the quanity. can somebody send me a javascript code that can do so … | |
How to store values that are retrieved from mysql database into an arraylist? |
The End.