43,549 Solved Topics

Remove Filter
Member Avatar for
Member Avatar for frogboy77

Hey there. I'm trying to figure out how to subtract one array of integers from another. I have figured out how to add 2 together going digit by digit and carrying over. I have no idea how to go about subtracting one from another. Basically i want to do simple …

Software Development c++
Member Avatar for frogboy77
0
208
Member Avatar for SgtMe

I have made a python program which will create an OpenGL and render a teapot (GLUT standard teapot) with a shader that I specify. The shader is specified as follows: [LIST] [*]I have a file called "index.ini" which contains the file paths to a vertex shader and pixel shader file …

Software Development c++ file-system opengl
Member Avatar for SgtMe
0
484
Member Avatar for stemiros

Hi, I need some help with OpenGL and rotation. I have a 3D door surrounded by a holder. The holder needs to move with the door and rotate when it's not on the floor. After that the door must be able to open without affecting the holder. It's based on …

Software Development c++ image opengl
Member Avatar for daviddoria
0
386
Member Avatar for kk12345

Hey, So I need help with fractal project, Pythagoras Tree, and below is the code i need to complete. And I really have no idea how to finish. [CODE]from PIL import Image from movieSolution import * import math class ETree(GO): #---------------------- Begin given functions ---------------------------- def __init__(self, color, initSize, order, …

Software Development python
Member Avatar for TrustyTony
0
375
Member Avatar for Peter_TARAS

Hi, I try to read line by line from a file some data. Each line in that file has the following format: x = 78.36734693877551, z = 11.428571428571429 -> amplitude: 8.62847057093655E-6 | phase -1.5707968246742405\n I am trying to extract those four float numbers using regular expression. I came with the …

Software Development python regex
Member Avatar for Gribouillis
0
180
Member Avatar for liran

( It is only in Python 3 ! ) ( The commands to operate this file are at Linux ! : I want to read a file, but it has to be through stdin ( In linux, with "< filename" ) ! And I want to write the same file …

Software Development file-system python
Member Avatar for Gribouillis
0
2K
Member Avatar for Philosophy

I am working on the last part of an encryption/decryption program and have to compare the original input file to the final output file character by character to ensure that they are identical. I have tried a few different ways to do this to no avail. When I tried this …

Software Development c++ encryption
Member Avatar for Philosophy
0
497
Member Avatar for KA2806

Hi i am trying to create a function that asks the user to enter height and width then colour to then display each pattern in the selected colours. i made a start but i cant make it work with the colour nor adding size dimensions. [CODE]# mini_project.py from graphics import* …

Software Development python
Member Avatar for woooee
0
80
Member Avatar for ceyesuma

Hello. I am not sure how this is supposed to work. I need to find a file that will be in a folder data/gm in my package. If I move the program around is there a way to have the program find its new absolute path [icode].getAbsolutePath()[/icode] from its path …

Software Development java
0
75
Member Avatar for AMetnik

[B]Hej i am getting the error:[/B] [CODE]error C2440: 'initializing' : cannot convert from 'int *' to 'GarbagePointer<T>' 1> with 1> [ 1> T=int 1> ] 1> Constructor for class 'GarbagePointer<T>' is declared 'explicit' 1> with 1> [ 1> T=int 1> ][/CODE] -------------------------- But i really dont know how to either …

Software Development c++
Member Avatar for daviddoria
0
2K
Member Avatar for ghosh22

Hi everybody..Here's an interesting problem to solve. I have a text file like this (also attached): [CODE]>first TTCCCAAAAAAGACCTACTAAGTCAAGCGGATGCGTTTTGTGTCTTATGG AAAGTCCCTGACGGATACGAGGCTTTGGGTGATTCGGTACGAATGATTCG GTTACCAGAACTTACCGAAGAAGAAATGGGACGAACCGAGGTTTCTCGTT CGTGTGCTAATCCTACATTCAAACATCGATTTCGATCAGAGTTTGTTTTT CATGAAGAACAGACATTCGTATTACGTGTTTACGATGAAGATTTGAGGTA >firsta TTCCCAAAAAAGACCTACTAAGTCAAGCGGATGCGTTTTGTGTCTTATGG AAAGTCCCTGACGGATACGAGGCTTTGG---------------------- -----------------AAGAAGAAATGGGACGAACCGAGGTTTCTCGTT CGTGTGCTAATCCTACATTCAAACATCGATTTCGATCAGAGTTT------ CATGAAGAACAGACATTCGTATTACGTGTTTACGATGAAGATTTGAGGTA[/CODE] Both >first and >firsta containing same characters except the part with hyphens. Now is it possible to write a perl script that …

Software Development perl
Member Avatar for ghosh22
0
158
Member Avatar for Daita

I have a statement in c as 3*3*3%4 and the output is 3 how is that?

Software Development c
Member Avatar for Shankye
0
110
Member Avatar for sToXiC

Hello all. I have a string, e.g. "Testing" and I try to convert it to byte but I get a NumberFormatException. I tried with (byte), Byte.Parsebyte. Any help? thanks

Software Development java
Member Avatar for sToXiC
0
162
Member Avatar for Oregand

Hi guys, This week Ive been given a problem to: Take a set list of English phrases and convert them to a set list of pirate phrases. i.e. Hello would be entered by the user and Ahoy would be printed etc. My idea is to create two arrays, One will …

Software Development java
Member Avatar for Oregand
0
140
Member Avatar for CanofCornInfini

Hello, I'm new to C and I'm not sure what is wrong with my code here. After I execute, I get this: Debug assertion failed! [program address] File: fgets.c Line: 60 Expression: str != NULL It's a really simple program. I'm trying to assign family data from the in file …

Software Development c
Member Avatar for Shankye
0
541
Member Avatar for Gaiety

below is the code for traversing a binary tree without using recursion but the problem with the code is we require array of pointers to store all the nodes address. in below program the parameter nodes in the function push is an array of pointers to store all the node …

Software Development c
Member Avatar for jl.lakhnai
0
179
Member Avatar for novice20

[B]hi all, can anyone tell me how to open a folder on a remote machine connected on same LAN. I need to open a folder in the form "\\remote_machine\folder1\folder2\folder3"[/B]

Software Development python
Member Avatar for novice20
0
3K
Member Avatar for adams161

hi, I have the line of code: [code=vb.net] xlWorkBook = xlApp.Workbooks.Open("c:\mydocs\full_info.xlsm") [/code] my problem is i want to load the file without a full path, "full_info.xlsm", but i can't seem to find the right place to put it. i have the program name directory which contains folder 'bin' 'myproject' 'obj' …

Software Development vb.net visual-studio
Member Avatar for kvprajapati
0
125
Member Avatar for jrp370

ok so i really dont understand this whole recursive stuff and i need some help on a simple program. the problem is to write and test a recursive function max to find the largest number in a list. here is a non recursive function that ive made, [code] def Max(li): …

Software Development python
Member Avatar for Gribouillis
0
2K
Member Avatar for optikali

Hello all! I am starting to write a little roulette game and while trying to print out my arrays to make sure they contain the correct values the compiler keeps screaming this at me: "non-static method .... cannot be referenced from a static context" Any pointers would be greatly appreciated! …

Software Development java
Member Avatar for optikali
0
90
Member Avatar for balrogf

i'm almost done with my video poker game. i need help finding the if the winning hand is a straight(a straight is five continous cards e.g. 3,4,5,6,7, ive made J,Q,K,A 11-14) HERE'S A CODE SNIPPET: [code] int[] arraydeck = { "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", …

Software Development video-card
Member Avatar for balrogf
0
159
Member Avatar for Kirielson

Here's my problem, I am getting a bad access on a shared memory line on my producer/consumer program: [CODE]Program received signal EXC_BAD_ACCESS, Could not access memory. Reason: KERN_INVALID_ADDRESS at address: 0xffffffff 0x00001db0 in main () at Project3.c:120 120 memset(buf, 0, BUFFER_SIZE); [/CODE] [CODE] int BUFFER_SIZE = 200; int *buf; [I]Some …

Software Development c
Member Avatar for Kirielson
0
161
Member Avatar for vbprogrammer1

Hi, Can anyone tell me how to remove spaces in a line which contains more spaces in vb.net. Eg 12 25.53 35 It should be read as 12 25.53 35 Thanks VRP

Software Development vb.net
Member Avatar for vbprogrammer1
0
139
Member Avatar for CallumP93

Hi All, I am currently making a server monitoring application that pings the server to check its uplink, so far it creates all the picture boxes and labels for each server, and then pings the server, although I have a picture that I want to change dependant on the result. …

Software Development image vb.net visual-basic
Member Avatar for CallumP93
0
229
Member Avatar for kerp

Hi, I've ran into a problem with pointers which I can't seem to get my head around. Here's some code that illustrates my problem. [CODE]void Reallocate(char* Source) { int NumberTest = 0; char* Buffer = new char[4]; memcpy(Buffer, Source, 4); delete[] Source; Source = Buffer; memcpy(&NumberTest, Source, 4);//This puts the …

Software Development c++
Member Avatar for kerp
0
117
Member Avatar for acrocephalus

Hello! I'm just beginning to learn Python and I would like you to recommend me any good tutorial. I have started with the [URL="http://www.pythonlearn.com/"]http://www.pythonlearn.com/[/URL] and the [URL="http://hetland.org/writing/instant-python.html"]http://hetland.org/writing/instant-python.html[/URL]. I have found them very useful and I would like to continue learning. Furthermore, I would also like to start learning on programming …

Software Development python tkinter
Member Avatar for Dylan Solarsh
0
239
Member Avatar for piratesocrates

Hello, I'm still pretty new at this so all suggestions are much appreciated. When I set the button background image in properties, it looks great. When the button is clicked, the image needs to change. I tried to use an image list like this: [CODE]btnSample.BackgroundImage = ImlStimuli.Images.Item(0)[/CODE] and I tried …

Software Development vb.net
Member Avatar for piratesocrates
0
10K
Member Avatar for james6754

Hi everyone.... [code] public void LoopGrades() { try//Start try block { //Start TextReader TextReader grades = new StreamReader("grades.dat"); ResultOfData = grades.ReadLine(); } catch (FileNotFoundException e) { MessageBox.Show("File Not Found!", "Error"); } //Loop through grades while (ResultOfData != null) { //ResultOfData is given the value that is read from grades.dat ResultOfData …

Software Development
Member Avatar for james6754
0
130
Member Avatar for coril

I'm trying to figure out how to set up a grid using a list of lists. I want the input to be x where the program will then setup a list of x lists, each containing x entries, in this case "0"s.

Software Development python
Member Avatar for Gribouillis
0
265
Member Avatar for Firo

Mhm, so, the problem I'm having here is that, once the "while (!boatList.eof())" cycle reads the first line (EDIT: I meant, how should I put it, the first "segment"), it goes on infinite (?) loop reading the other one. [QUOTE]AX 777 Valtis 0 4 500 2007 5.5 -1 50.2 6 …

Software Development c++
Member Avatar for Fbody
0
177
Member Avatar for rx21825

I am new to python programming and struggling with a problem I would like help with. I have multiple text files that I would like to join using the first column in each file to serve as the key to align the files. Each file could be several hundred lines …

Software Development python
Member Avatar for TrustyTony
0
2K
Member Avatar for steve_Student

Hi can any one help me with my if / else statement, I have an assignment which has to give discounts to phone calls depending on the time of call or the day. Here are the discounts Starting Time--------------Monday to Friday-------------Saturday and Sunday Before 8am-----------------40% discount-----------------60% discount 8am to 4:59pm--------------Regular …

Software Development c++
Member Avatar for Jason Giggs
0
148
Member Avatar for nexus490

Hey all, i have written a short program which outputs a basic Histogram in this form: (0-25) *** (26-40) **** (41-75) ** (76-80) **** (81-100) ** I'm required to alter my solution so as well as that it also outputs it vertically so i'm after something like this: * * …

Software Development java
Member Avatar for nexus490
0
113
Member Avatar for xikkub

Using GLUT, moving my mouse in the display window causes the animation to increase in speed. When running at an initial 60fps, moving the mouse causes the animation to accelerate and increase to 1000fps. My data might be wrong, but there is definitely a timing issue. I've tried implementing a …

Software Development c++ opengl
Member Avatar for xikkub
0
312
Member Avatar for Mona..

Hi.. I want to compress a text file which is like this:(input.txt) [CODE] ffa11 ffb13 ffd2 e c e r [/CODE] and save the result in (output.txt) [CODE] #include<fstream> #include<iostream> using namespace std; int main() { char ch; int counter=0; fstream infile; fstream outfile; infile.open( "input.txt",ios::in ); outfile.open( "output.txt",ios::app ); …

Software Development c++ ios
Member Avatar for xikkub
0
1K
Member Avatar for Philosophy

I am working on an Encryption/Decryption program for class and have run into a problem. I seem to have gotten the encryption correct, but I am unable to decrypt what was encrypted in order to get an output equal to what originally went in. Here is the code I have …

Software Development c++ encryption ios
Member Avatar for Philosophy
0
279
Member Avatar for LianaN

Hi! I have a Java application that works with MySQL DB. Until today I used latin alphabet, but now I would like to extend my application to working with cyrillic alphabet. As far as I know, it is possible to use UTF-8. But I don't know the way, in which …

Software Development java mysql
Member Avatar for LianaN
0
306
Member Avatar for Theformand

Hey all. I have a deadline tomorrow, and this thing is killing me, so I come to you with hopes of help. I have a couple of classes. An info class, which converts a string to ints and puts it in the [B]values[/B] array. Another class (plotter), is supposed to …

Software Development java java-swing multithreading
Member Avatar for Theformand
0
162
Member Avatar for TheDocterd

Hi there How can i get the checkbox's value from sql server 2005 and display it in my windows application? The checkbox column in my database either has two values, checked or unchecked. Now what I want to do is I have a form where I can view data. That …

Software Development display
Member Avatar for TheDocterd
0
2K
Member Avatar for ghosh22

hi guyz..how r u? I am facing a problem with a simple Perl script. I want my code to calculate the length/number of letters present in a text file (which is the input). But it should skip the line starting with '>'. The input used is given below (also attached). …

Software Development perl
Member Avatar for ghosh22
0
317
Member Avatar for dreamer_lek91

there are quite i few data that are required to update in one time... And the default setting for a list box is that u need to update once at a time? Can any1 plz teach me how to select 2 or more item in the list box and update …

Software Development microsoft-access visual-basic
Member Avatar for AndreRet
0
149
Member Avatar for _neo_

Hello! I'm new in java. I need some help, guys. How can I determine in Java next run time of cron-like job? For example, if I have crontab entry without command, like [I]"*/15 * * * *", every 15 minutes "5 */2 * * 1", every Monday at 00:05, 02:05, …

Software Development java
Member Avatar for _neo_
0
3K
Member Avatar for neosonic

Hey all, I have a picture box, and I want to detect whether the ctrl key is being pressed. Since I want to simulate... ctrl and left click for multiple selections. what I have done: 1. set beingpressed as boolean 2. in keyDown event, I set beingpressed to true 3. …

Software Development visual-basic
Member Avatar for AndreRet
0
746
Member Avatar for abelingaw

Ok i have this form used for registering user for my program (User and Admin type) When i run it, i get an error that says "Invalid Property Value" This is my code for my GetUsers function called on my Form_Load event [CODE] Public Sub GetUsers() ' On Error GoTo …

Software Development listview visual-basic
Member Avatar for AndreRet
0
145
Member Avatar for unika010690

i have a project my next task is to display the item selected from my listview to the textbox in the other form heres my code on the listview Public Class listemployee Private Sub listemployee_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load ' Create the column headers. ListView2.Columns.Add("EmployeeID", …

Software Development display listview vb.net
Member Avatar for codeorder
0
6K
Member Avatar for b1izzard

Hi all, I want to compile the cobol program with a click of a button in toolbar provided if its compiler location and command to compile is specified. e.g [CODE] c:\cob>cobol hello.cob 'command line equivalent [/CODE] VB equivalent: [CODE] Dim command As String command = "cd " & app_path 'app_path="c:\cob" …

Software Development shell-scripting visual-basic
Member Avatar for b1izzard
0
183
Member Avatar for Toxic_Rice

Hello, everybody! I am kind of new to the forums, and I will do my best to follow the rules when posting a new thread. I am to create a program that is supposed to generate 30 random integers between 10 and 200, and insert them into a Heap. The …

Software Development algorithm c++
Member Avatar for Toxic_Rice
0
237
Member Avatar for adams161

I'm a little self taught at java. I have a package: package: package org.newdawn.spaceinvaders there's folders like org and newdawn are created and nested. the main is Game.java at end of those folders. How do i run it? i went to the end folder and typed java Game that didn't …

Software Development java
Member Avatar for adams161
0
95
Member Avatar for kerp

Hi everybody, this text turned out to be rather long and maybe not so clear, please excuse me. I'm currently using the winsock library to send and receive data in an application made with WinAPI, I'm not using MFC. I'm using asynchronous sockets (I think that's what it's called) which …

Software Development c++ microsoft windows-api
0
181
Member Avatar for corrwee

Hey guys I'm having some trouble with a homework question from Zelles python. I have to make a Set class then test a variety of methods. However my teacher wants us to just use lists and not actually sets. I'm getting an error for the setElements method, it keeps saying …

Software Development python
Member Avatar for SgtMe
0
248

The End.