199,114 Archived Topics
Remove Filter ![]() | |
how can i shyow this output using a single for loop? `0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20` `0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 … | |
hi plz tell me the coding of exception handling in java.. | |
Currently this method has a run time of O(N^2) and I am trying to get it to O(N). Any suggestion as to where I should start? public void removeAll(e removeNum) { node nodeToFind = this.find(removeNum); while(nodeToFind != null) { this.remove(nodeToFind); nodeToFind = this.find(removeNum); } } Thanks | |
Let's say I have an array/arraylist(doesn't matter) with the following content: 2, 2, 2, 4, 5, 5, 8, 8, 8. How wold I go about counting the different values, in other words; how would I find out that there are 3 twos, one 4, 2 fives and 3 eights. How … | |
Currently I'm using netbeans 7.2 using glassfish server. I want to put two numbers using HTML+ Servelet. I'm just a beginner I have no idea. Would somebody help me? I also don't know why I got error: Incompatible types required int found string although I used parseInt to convert String … | |
Please let me know the detailed procedure to install Apache, MySQL, PHP and PHPmyAdmin on my system which is windows 7. or post a link where the complete installation is given. I do not need to work on XAMPP or WAMP or such kind of other softwares. you can also … ![]() | |
AH 1106 AH 11989 AH 121 BH 120 BH 220 CH 330 I want result like AH 1160 11989 121 BH 120 220 CH 330 | |
how can i replace the array notation with pointer notation #include<stdio.h> #include<stdlib.h> #include <math.h> /* 4 */ void run_sieve(char *, int); /* 5 */ void print_primes(char *, int); /* 6 */ int main() { /* 7 */ int i, top; /* 8 */ printf("compute primes up to: "); /* 9 … | |
spring model....i want to get the program to return the value of the period of the motion of the pendulum i have tried putting this outside the loop oldVelocity = vector(0,0,0) and this inside the loop before v: oldVelocity = m.v with print statement: if oldVelocity.y/m.v <0: print ("time = … | |
Hi there Im trying to write up a code where two txt files are being compared to each other. One text files has the answer like "TFTTFFT" and the other txt files has the result including id like "1234 TT-FFT" The crazy part is that for each correct answer, the … | |
I have a two forms that I created using the design view of Visual C# Express (Form1 & infoEntry). I set the properties to of the listview in Form1. public System.Windows.Forms.ListView toSend; I've invoked the second form and sent some data using code below. Works great. infoEntry dataWindow = new … | |
#include <iostream> #include <fstream> #include <string> using namespace std; const int numRows=5; const int numCol=7; void openfile(ifstream& , ofstream& ); void initialize(ifstream& , ofstream& ); void ave(ifstream& ,ofstream& , double , double,string ); void printout(ifstream& , ofstream& ,string ,double ,double ); int main(){ ifstream infile; ofstream outfile; string names[numRows]; double … | |
i am retrieving textual data from database on my page , asp.net(c#), now i want to save in pdf format and want to store that pdf file on my server(localhost) so how ? | |
Hi.. can anyone tell me what is the meaning of this error?? [Error] cannot convert 'std::string {aka std::basic_string<char>}' to 'char*' for argument '1' to 'char* strcpy(char*, const char*)' When I'm taking TeamName as char TeamName[30]; , the compiler shows linker error. what could be the problem? I use DEV C++ … | |
Hey guys I have a wierd issue that im not sure how to fix. If a users starts timer1 it will open form that has a timer and continue allowing them to choose other options. BUT the sendkeys do not go through until the timer is up and the form … | |
Dim num1, num2, sum As Double num1 = txtFirstNum.Text A variable input any number can go here num2 = txtSecondNum.Text A variable input any number can go here sum = num1 + num2 txtoutput.Text = sum My goal is to have the txtoutput show the equation 2 + 2 = … | |
I am working on this project and i am going to need to write information and retrieve them from a file. I get all the information needed but i am not sure how to write it to a file and how to get it back. if (id.is_open()) { cout<<endl; cout<<"Enter … | |
Hi, I am using below PHP script for insertion in mysql table from CSV file. Below code is working fine but i am trying to leave first row of CSV as it contains heading for data. need suggestions as it is reading from very first row. <?php //connect to the … | |
For an assignment for class i wrote this code right but the only problem i have is that i can't get the right value that assignment wants which is distance so far: 0 meters distance so far: 1000 meters distance so far: 0 meters distance so far: 0 meters distance … | |
I'm still a little confused. Basically this is what I'm trying to do, and I'm having one hell of a time with it... My program has two values "Value" and "N". The goal of the program is to select every Nth number of Value starting with the last, and print … | |
i wrote this code for sending and recieve mail but i can't get the output that is required for class which is -Test 1-- Creating a new envelope Addressing from Muffin To Howie Inserting the message: Pet me! Affix Postage: 0.33 stamp Sealing the envelope Mailing the envelope --Test 2-- … | |
I'm getting this error message when I go to my login page: Warning: Cannot modify header information - headers already sent by (output started at /home/a4259hos/public_html/ebookadvisor/wp-config.php:40) in /home/a4259hos/public_html/ebookadvisor/wp-includes/pluggable.php on line 881 Can someone help me with this? ![]() | |
try { mysql_query("INSERT xyz"); mysql_query("INSERT xyz"); mysql_query("INSERT xyz"); commit() } catch (Exception $e) { rollback() } I would like so that if any of the queries within the try { } fails, to go to the exception and rollback the transaction, and commit otherwise. What kind of things will it … ![]() | |
This little experiment with Tkinter and pixel drawing shows some strange effects (look at line 27 comments!!!): '''tk_put_pixel.py place a pixel at pos=(x,y) with color=(r,g,b) on an image area note: one pixel might be hard to see, so create a series of pixels (line) ''' try: # Python2 import Tkinter … | |
Well, I have a code that just won't run. It says it has a syntax error, but I've been looking at this code for 20 minutes and haven't found any. Could you guys plese tell me if something is wrong? // $anio holds the name of my table. $query="INSERT INTO … | |
python help on making the program accept other values? # Find the area and perimeter of a rectangle import math class Rectangle(object): """A 2D Recangle""" def __init__(self, width = 1, height = 2): self.width = width self.height = height def Perimeter(self): "Return the Perimeter of the rectangle" return (2 * … | |
Hallo Im new in the game programming world with C++, really new! I want to make a 3D game.I installed today VS 2010 because I heard that there are unfixed errors(since 2005). I have a couple of books called " beginning C++ game programming" , "mastering Autodesk 3ds mask 2013"( … | |
this is practice is require to create 3 class when I click load button I should get flight number ,day,time, destanation , pilot , co pilot I should get this http://s17.postimage.org/52smv6jl9/screenshot_A1.jpg every thing seem to be right I didn't get any red lines , but I can't find where is … | |
I developed an Android FlagGuessEnRu game, but I want upon success flag guess go to Google Maps(browser or MapView) for that flag/country, with appropriate scaling of the Map per country, well i get countries from wikipedia, what url to use for google map for a particular country, how from country … | |
using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Windows.Forms; using System.Drawing.Drawing2D; /* * @(#)fractal.java - Fractal Program Mandelbrot Set * www.eckhard-roessel.de * Copyright (c) Eckhard Roessel. All Rights Reserved. * 06/30/2000 - 03/29/2000 */ //import java.awt.*; //import java.applet.*; //import java.awt.event.*; /** * @version … | |
TypeError: 'float' object has no attribute '__getitem__' What does this mean ??? | |
I have been working with Java a longtime, but my main problem is this. Everytime i try to set my classpath, set my path variables, all works well, until i think of adding a new package from elsewhere. Disaster breaksout, such that i have to recode the entire package for … | |
I would like to find a method where i can find a character position in reverse.For example last "e" starting count in reverse. From example $string="Kelley"; $strposition=(strpos,'e'); it will give me position 1. | |
I have a text file that i would like to display a part of so i use this code: <?php $page = file_get_contents('news.txt'); echo $page; ?> But in news.txt if i have this code `<?php echo"hello world!"; ?>` It will not display... when i look at the source code of … | |
Anyone has idea to seperate a word in parts for example ( kalemimin -> kalem-i-min ) 'kalem' is str1 , 'i' in str2 and 'min' should be get into str3. | |
i have a problem on how to code for automatic generate an employee id whenever i registered an account in my system. i used asp.net as my front end and Sql Server Database 2005 as my back end.. thnx a lot! | |
Good day! I just need a little help on how to create this program the precise way. Example if the user will enter 123450, it should output the sum of all individual integers, in the example the result must be 15. If the user will enter a character or a … | |
error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1 Its valid sql I checked I just don't understand what would cause that error. I also tried different statements and … | |
The code below should be extracting the pixel data from the mapProvinceFile bitmap specificed and placing it into a byte array, modifying some of that color data depending on the contents of a custom ArrayList, vertically flipping the image, and then displaying the resulting modified image in a new pane. … | |
I am looking for a project or goal to reach in order to improve me programming skills. I'd say I am still a beginner as it comes to C programming and would like a project to work on but cannot seem to think one, any ideas? | |
So, I have to find rhyming words. Basically I am getting a bunch of words and I need to compare which ones rhyme. So if I am given words like... friendl|y, luck|y, murk|y, rapidl|y luc|ky, mur|ky frien|dly, rapi|dly They can also rhyme with other words, so a word could appear … | |
`Inline Code Example Here` I have been trying to solve this but i just can't get it right... can someone help me pls? Using array to summarize survey results 40 Students were asked to rate the quality of the food in the student cafeteria on a scale of 1 to … | |
Hi everyone, Here I have a php code, and i want to understand one part of it - like what is actually going on over there. (Based on Model View Controller(MVC) format) This is my 'model/category_db.php' - file It connects to the database and has some functions that have a … | |
Hello, It appears that I'm having a slight problem with a pesky ArrayIndexOutOfBoundsException when trying to assign a value to an array embedded within an object. I *think* it's because the array hasn't been instantiated before I try to add values to it's index. The purpose of the program is … | |
Hi i have an htm created by ob_start--ob_clean (query from mysql) i can have more than 1 html each one for a user these htmls are converted to pdf using html2pdf and each file is called by the name of the cleint ex:if the user name is xxxx===>he will get … | |
ran into a little snag with my code. i am trying to push the data of all the nodes in a linkedlist into a stack. problem is, i have no idea how to properly convert a node into a variable. Node current = list.returnHeadNode(); //other code... stack.push(current.getData()); my error lies … | |
Hello I want to turn on a LED using C, meaning that I want to write on printer port. but the code doesn't work. I use char ledStatus instead of BYTE ledStatus. is there any difference?? what is the problem in this code? #include <windows.h> #include <conio.h> #include <staio.h> #define … | |
find and delete specific line from text file ==== cart.txt (tab delimated) ---------------------- guiburi PID001 KARLSTAD Sofa 2348 2 4696 guiburi PID002 BESTA Cabinet 1656 32 52992 guiburi PID009 PAX Wordrobe 1794 2 3588 deleteitem.php ---- if(isset($_GET['pname'])) { $pname = trim($_GET['pname']); } Info -- pname is sent from a another … | |
Hello, I am solving the assignment by Faculty Dean.but I face with that problem CS=1000; AX=0001; IP=0006; SP=0038; DS=2000; BX=0004; BP=0005; ES=4000; CX=0005; SI=0008; SS=5000; DX=4477; DI=0009; SUB [BX],CL; and another problem ADC DL,[BX]; footnote:these problems do not depend on each other |
The End.