132,726 Archived Topics

Remove Filter
Member Avatar for
Member Avatar for crystality

Hi! I'm trying to implement an optimization idea for Dijkstra's algorithm for homework. This is the optimization idea that they want us to implement: [INDENT][B]Idea 3. [/B]Many of the vertices have exactly two neighbors. If a vertex [I]v[/I] has exactly two neighbors [I]u[/I] and [I]w[/I], then you can replace the …

Software Development algorithm c++
Member Avatar for crystality
0
174
Member Avatar for Tech B

I am currently a student in computer Information Technology and I would like to ask those of you who are experienced working in this field. I didn't really know what forum to post this, so I am posting in Python because I love the language and have posted here before. …

Software Development python
Member Avatar for Tech B
0
93
Member Avatar for doodads

Alright I've pretty much exhausted all other sources of information and still can't seen to understand how to do this, so here is my question: I have a program that loads up a txt file, then displays a menu and allows people to choose options from that menu. If they …

Software Development java
Member Avatar for doodads
0
201
Member Avatar for Stivdion

i Am beginner to c++, so bear with me i can seem to fix these errors error c2109 subscript requires a pointer or arrays [code=cplusplus] //Stephen Igbinedion //CMPS //Due Date; Dec 4th 2009 //Programming Assignments 6 (Final assignment for CMPS 1043) //This Program orders a set of integers. #include <iomanip> …

Software Development c++
Member Avatar for Stivdion
0
236
Member Avatar for PDB1982

This is a stupid question, but for the life of me, I cannot remember how to create the "Or" symbol in code....(the two vertical lines...)...how do I do it?

Software Development c++
Member Avatar for PDB1982
0
52
Member Avatar for Kuroshi

I tried to create an array that would increase its own size depending on the user's action. For example: The user types the name of one contestant, the array contains only one element (the name), later the user enters another contestant, the array becomes an array of 2 elements, each …

Software Development c++
Member Avatar for Kuroshi
0
174
Member Avatar for RoyMicro

I have a microsoft report viewer generated report with tables and all. I have images also in the report. I have to load a image control with a image at the time of report generation. embedded images seems to be from design time. I found some posts to this subject …

Software Development image
Member Avatar for kvprajapati
0
172
Member Avatar for PinoyDev

Good day! I just need some help/solution on how to prevent the user to resize the form when the width of the form is less than 8,220. Thank you guys for giving time. God bless

Software Development visual-basic
Member Avatar for PinoyDev
0
150
Member Avatar for C++NOOOB

Hi, I am learning inheritance and abstract base classes. I need to define an abstract base class (ABC) that provides interfaces, and a derived class (directly from the ABC) that provides the implementation. The derived class may need additional member functions and variables (both, public and private). Using a pointer …

Software Development c++
Member Avatar for Ancient Dragon
0
130
Member Avatar for Tauren

Hello, I just wanted to say Something about OS I read the one march 2004 topic But if I read a book on C and c++ Will it show me how to do like programs Is there a site that shows me how to make a OS?

Software Development c++
Member Avatar for Ancient Dragon
0
547
Member Avatar for keicola

Hi... I've been trying to edit and rewrite my code for quite a while now but no matter what I do the program only ever reads the last instance of a class that I declare. For example, [CODE]Fraction ni = new Fraction(3,4); System.out.println(Fraction.lcd(ni,new Fraction(3,2)));[/CODE] > This code is supposed to …

Software Development java
0
63
Member Avatar for jh9t

Hi, Daniweb I am stuck on my hangman game project, I don't know where to start with my last four methods [code] import java.util.*; import java.awt.*; import java.applet.*; import java.io.*; import java.net.*; public class Hangman() { final int maxTries = 5; final int maxWordLen = 20; char secretWord[]; int secretWordLen; …

Software Development gui java
Member Avatar for mellowmike
0
114
Member Avatar for Gem74

need help, what I need to do is have the status function run before each withdrawl to let the user know if the account is active or inactive. Active = balance > 25, if account balance <25 then no withdrawls can occur. I have the following: #include <iostream> #include "Savings.h" …

Software Development c++
Member Avatar for Gem74
0
84
Member Avatar for moods125

#include <iostream> #include <iomanip> using namespace std; //global constants const int SIZE = 12; //function prototypes bool getAverageRainFall(double rain[SIZE]); bool getExactRainFall(double rain[SIZE]); void displayResults(const double actual[SIZE], const double average[SIZE]); void printMonth(int month); // PRECONDITION: month holds an integer 1-12 // POSTCONDITION: the corresponding month (Jan, Feb, ..., Dec) has been …

Software Development c++
Member Avatar for moods125
0
202
Member Avatar for americanfire

Hello, I need help with re-ordering the values in ascending order in the array Unordered. However, I cannot use sort or swap functions. The values in array Index are used as indexes of array Unordered to put the values into the sequence shown in Ordered. I am writing this code …

Software Development c++
Member Avatar for americanfire
0
144
Member Avatar for Goalatio

Hey again everyone, it's been a while since I've posted here.. What I'm trying to do, is get the command-line argument and convert it to hexidecimal. Example, if the file is named 'test', you would call it with test 72 Or something similar. I have it working, but after MUCH …

Software Development assembly storage
Member Avatar for Goalatio
0
296
Member Avatar for Chris11246

Im making a sim of a robocup for a project and it would really help make the code easier to read if I could have an array of players but I cant dim and array as new and my players are all a class I made called gameobject. How do …

Software Development vb.net
Member Avatar for Chris11246
0
114
Member Avatar for confusedndazed

Hello all, I'm very confused on this K factor stuff.....I understand that...1*2*…*k indicates the product of consecutive numbers and therefore: 1*2*…*5 is actually 1*2*3*4*5 = 120 But I'm not sure how to write that as a code. I have the following information: /* pseudocode for Binomial Coefficients */ int binomial(int …

Software Development c++
Member Avatar for confusedndazed
0
153
Member Avatar for MegadanX5

Hi everyone, this is my first post on this site and I was wondering if anyone could help me with this. I'm sorry if my coding style is strange, I'm relatively new at this. The program is supposed to prompt the user to guess a number between 1 and 1000, …

Software Development c++
Member Avatar for MegadanX5
0
160
Member Avatar for G_Waddell

Hi, I'm writing a function that takes a word doc and returns the number of pages in it. I have the function working and returning pages except that it opens a Word dialog asking if I want to save changes - does anyone know how to stop this? I have …

Software Development vb.net
Member Avatar for phatJacob07
0
1K
Member Avatar for ntouros

[code=c#] private void button1_Click(object sender, EventArgs e) { if (openFileDialog1.ShowDialog() == DialogResult.OK) { pictureBox1.Image = Bitmap.FromFile(openFileDialog1.FileName); org = (Bitmap)pictureBox1.Image.Clone(); } } private void button3_Click(object sender, EventArgs e) { if (saveFileDialog1.ShowDialog() == DialogResult.OK) { pictureBox1.Image.Save(saveFileDialog1.FileName); } } private void button2_Click(object sender, EventArgs e) { Bitmap temp = (Bitmap)org.Clone(); ot.Convert2GrayScaleFast(temp); int otsuThreshold= …

Software Development c#
Member Avatar for ntouros
0
221
Member Avatar for kaydub123

I have a hmwk assignment that i'm stuck on....It calls for a while loop so I need to basically repeat this 4 times but I cannot for the life of me figure it out....any help would be great I narrow the code down so it works when I input the …

Software Development python
Member Avatar for masterofpuppets
0
742
Member Avatar for Geodude0487

This may sound like some simple stuff but I'm getting lost and my professor is hard to reach so if anybody can help me I'd greatly appreciate it. I'm writing sort of like a bank program, there is a "log-in" form, a "registration" form, and a "data access" form. My …

Software Development
Member Avatar for Geodude0487
0
209
Member Avatar for ahspats

i want to write a simple app which does nothing else except that you can drag an image in a window(simply clicking somewhere on the screen and moving mouse while holding the left button down). The problem is that my image moves only once and only a little bit and …

Software Development image os-x python
Member Avatar for masterofpuppets
0
384
Member Avatar for songweaver

Hey guys, The idea with this form is to add the futures which is calculated when the button is pushed but I need the list to update every time and show the values each time to which the previous value is added to the new calculation, e.g. of what it …

Software Development vb.net
Member Avatar for songweaver
0
141
Member Avatar for confusedndazed

Hello people, this is my second attempt to get help for the same code. First post is unsolved. I apologize for any confusion in my posts but I'm confused myself so it's somewhat hard for me to properly explain that which I don't even understand....:$.... I have been given the …

Software Development c++
Member Avatar for lotrsimp12345
0
118
Member Avatar for PDB1982

Ok....I'm stuck again...I'm wondering if there is a way to sort the following code, so that I can pick out the highest value. I don't believe that I can make it into a list, since they are in parallel arrays. I'm hoping not to have to do a long set …

Software Development c++
Member Avatar for PDB1982
0
135
Member Avatar for gsingh2011

I need to save an object to a file and then reload it later on. I think this is called serialization but I don't know. I have made a simple example below that I need to fix. [CODE]#include <iostream> #include <fstream> #include <windows.h> using namespace std; #define MAXV 1000 class …

Software Development c++ ios
Member Avatar for Ancient Dragon
0
116
Member Avatar for bords

Hello...we are to make a project like "Text Twist"... but in the network connection form... maximum of four players so there will be also 4 computers connected by LAN... i just need ur advice guys f how could i make this project... is it about using database? when i tried …

Software Development visual-studio
Member Avatar for RunTimeError
0
95
Member Avatar for fatboyandy

Hi everyone This code works fine but the asterisks that print to represent the percentage is wrong. The example given was there was a total of 14 grades across the A-F range, but "A" had 1 and 1 should represent 4 stars one the chart. Whats wrong???? [CODE] #include <cstdlib> …

Software Development c++
Member Avatar for Murtan
0
117
Member Avatar for Diamonddrake

I need to be able to take a point on an image and convert it into a point relative to a picturebox with the pictureSizeMode set to zoom here is the code that the picturebox uses to scale and center the image [CODE] Size size = this.image.Size; float num = …

Software Development mathematics
Member Avatar for Diamonddrake
0
287
Member Avatar for nightninja12

i have to write a program database with investors names, ammounts invested, city, and the phone numbers. i have one binary search tree, unsorted where the key is the name and ammount, and a heap sorted by the ammount invested. now i need to display the top 3 cities (with …

Software Development c++
Member Avatar for lotrsimp12345
0
103
Member Avatar for lotrsimp12345

i believe that it checks every nodes height and makes sure that the left -right is 1 or 0 or -1. It is supposed to return tree if tree is balanced which means that left-right is 0 or 1 or -1 at every node. [CODE] template <class KT, class DT> …

Software Development c++
Member Avatar for lotrsimp12345
0
66
Member Avatar for losh177

Hi, I'm trying to manually translate 16-bit assembly intruction into the format Instruction Prefix-Opcode-ModR/M-SIB-Address Displacenebt-Immediate Data for an Intel8086. I'm having problems trying to figurit out when to use the respective values for the Mod, the R/M. If anyone could point a good book or site for this type of …

Software Development assembly
Member Avatar for losh177
0
154
Member Avatar for micke

Hi, how could you find the last digit in an integer? Thank you.

Software Development c++
Member Avatar for donaldw
0
270
Member Avatar for lewashby

In the following program, how does the value of [COLOR="Red"]crit_name[/COLOR], end up in the [COLOR="Red"]self.name = name[/COLOR] value? Is it because it's passed to that class and name is the only value in the [COLOR="Red"]__init__[/COLOR] parameter that has no default value? Thanks. [CODE]# Critter Caretaker # A virtual pet to …

Software Development python
Member Avatar for masterofpuppets
0
125
Member Avatar for MRWIGGLES

Hi, I am trying to write a snippet of code that checks if the user entered a valid color from an imported file called graphics.py. [code] # Get a valid color value from the user. color = raw_input("Enter a color: ")[/code] graphics.py contains a huge list of built in color …

Software Development python
Member Avatar for woooee
0
142
Member Avatar for simplyscottif

so I've got a lot of it done, I just need a hint as to the next step. So far I have the user entering a bank account, interest rate, and account balance. I need the user to enter an amount of years and the program will go through that …

Software Development c++
Member Avatar for Murtan
0
229
Member Avatar for Lida_pink

Can anyone help please? How can I give focus to a textbox (for example we have two) by defining a shortcut key as alt+m ? Thanks in advance Btw, I'm a beginner so please tell me in the simplest way. :)

Software Development visual-basic
Member Avatar for Lida_pink
0
173
Member Avatar for osirion666

[CODE] Dim name1(100) As String Dim Cal1(100) As String Dim i As Integer For i = 0 To 10 Step 1 name1(i) = GridView1.SelectedDataKey.Item(1) Next i [/CODE] i want to store the selected value into an array then display the array in a text box [CODE]Label5.Text = name1(0) Label6.Text = …

Software Development vb.net
Member Avatar for Geekitygeek
0
110
Member Avatar for laguna92651

I am starting to write a assembly program for a mc68hc12. I will be reading a 8 bit signed number into PortA and outputting the results to 7 segment LED's, common anode. I will be using Port P to ouput the segments and PortCan to control the LED's displayed. I …

Software Development assembly
Member Avatar for chrisname
0
115
Member Avatar for Yeen

I've got a bit of a problem. I've got a test tomorrow in python programming, and I've been learning the language using 3.1. The computers we're taking the test on all have 2.6 installed. They're Linux (not very familiar with Unix). Obviously this is troublesome. I don't want to spend …

Software Development python unix
Member Avatar for Yeen
0
155
Member Avatar for hondros

Hi there My Algebra 2 class just started matrices, and I don't want to go out and pay $100 for a graphing calculator, just for the matrices, when I can code one myself. So... this is my code, and I can do it without classes, but I decided to make …

Software Development python
Member Avatar for hondros
0
120
Member Avatar for marirs07

can anyone help me by telling how to save a diagram that ive drawn in C to a file?

Software Development c
Member Avatar for marirs07
0
91
Member Avatar for twalton42

trying to delete selectedItem from combobox to remove selectected account from database using mysql and vb.net 2008....this is my code for my delete menu can anyone help? *************************************************** [code] Public Class delete Public Sub _load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load 'TODO: This line of code loads …

Software Development vb.net
Member Avatar for Geekitygeek
0
330
Member Avatar for stevee1984

Hi all, and must say a great looking forum! I wish to start developing c++ apps on Linux and would like to know what GUIs are supports out of the box on Linux, especailly the main distros anyway? QT, KDE, GTK, etc? I basically want to write gui apps that …

Software Development c++ gui qt
Member Avatar for stevee1984
0
124
Member Avatar for lonprog

I have a project that I'm working on in C++ where I have to Search for Multiple Occurrences of a String in a Text File. Does anyone have code out there on how to do this? Thanks

Software Development c c# c++
Member Avatar for mrnutty
0
120
Member Avatar for mybluehair

So I have a game in c++ console, and it's pretty big now. (over 3 megabytes) I've been using strings in the code forever, but now, I need to make a separate exe program from scratch that will update the game when needed. Big problem - this new program is …

Software Development c c# c++
Member Avatar for Nick Evan
0
100
Member Avatar for CppBuilder2006

what's wrong with this code in VC++ 2008 Ex [CODE] #include <conio.h> #include <iostream> using namespace std; class Allocate { private: void* v; unsigned n; __int8 dummy_ret; void* Alloc(unsigned& n) { void* ret; if(n == 0) ret = 0; else { ret = new(nothrow) char[n]; if(ret == 0) n = …

Software Development c++
Member Avatar for CppBuilder2006
0
84
Member Avatar for merse

Sorry about my primitive questions but I cannot find a good summary about this basic topic. So I would like to write my own libraries: mylib.h and mylib.cpp. I need to include some standard libraries. But I dont want to overload them, what is the solution? I have to use …

Software Development c++
Member Avatar for Narue
0
150

The End.