132,726 Archived Topics
Remove Filter ![]() | |
PLEASE somebody help me I have QUESTIONS about pep/8 and 4 hours left to figure it out 1. in C++, global variable CHAR word[32] = "Backward"; is common but how do i initialize it in pep/8 ?? I need to write a simple program to flip it backward using stack … Software Development assembly | |
I am working on this program in Python that would allow me to scan for a certain phrase in a certain text document. I used the finditer function in Python's re library.The certain line of code resembled the following: [CODE]phrase=regex.finditer(page)[/CODE] I also had a print statement at the end that … Software Development programming-construct python regex | |
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++ | |
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 … | |
Well, I recently acquired Delphi for no apparent reason /shrug. And since I'm about to start learning a new programming language (haven't decided which one), I was wondering in Delphi uses Pascal. And if so, what can be done with Delphi/Pascal. What are some good resources for Pascal/Delphi. Online references … | |
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 | |
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 | |
Hi guys, I need help on getting the minimal scope on something. I am learning data structures, right now i'm figuring out how to insert my class information (strings, ints, floats) into my node class. Do i need to send data to my node each by each type? or is … Software Development c++ | |
Could somebody help me? This function should call to [B]make_schedule(temp_lim)[/B] until the returned value "gap" satisfies me. I know for sure (same function in c++), that "gap < 1" takes up to 10k-15k runs, ... ,"gap < 5" takes ~fifty runs. But here in C# it goes to "not responding" … Software Development | |
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 | |
write the header for a function named school which is public member of the class course, returns a string data type and includes 2 integer papameters named mark and grade.. i really don't know how to do that . any 1 please help .. thank you !! Software Development c++ | |
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++ | |
Ok, so i've got one definition on my python code, that defines how to find the position of something in an array, then returns the list of all the places that those things are. Then I've got another definition to find the accurate centroid of a position. How do I … Software Development python | |
class cube; private; float s1, s2, s3; public; void print(); float area (float, float, float); } the following class in incorrect any know how to write it correctly .. thank you Very Much For Help .. Software Development c++ | |
I am working on a project where I need to parse a bunch of user text that comes in different fields. The problem is that the user input doesn't always come in on the same fields. One user might have a name in field 3 and a date in field … Software Development open-source python | |
hi can i have a clock in my program when it runs the clock keep running like the computer time? and how? Software Development c++ | |
Hi friends, I would like to insert "whitespace" between the numbers of my string str3 and after concatenate with str1 and str2, as str1 << str2 << str3. This is an example: E.g.: 200 3 1 2 3 4 5 6 7 8 9 Could you help me? I had … Software Development c++ | |
As the title says: Is the XOR Swap algorithm still viable? I know that temp-swaps are supposedly faster but the shear coolness of an XOR swap makes it more attractive to me. What do you guys/gals think? For anyone that doesn't know what an XOR swap is here goes [code=c++] … | |
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 | |
I'm trying to create a tree using C and print its tree traversals(preorder,inoreder,postorder) so i decided to start creating a tree first. My program accepts a characters in preorder but it doesn't print the data I entered. Could someone help me? [code] #include<stdio.h> #define MAXNODES 26 void push(); void pop(); … Software Development c | |
Hi all, [code=xml]<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ABC="http://www.ABCSPGM.DSUPFREQ.Request.com"> <soapenv:Header> <ABC:ABCSHeader> <ID>xyz</ID> <ConsumerTransactionId>5667</ConsumerTransactionId> </ABC:ABCSHeader> </soapenv:Header> <soapenv:Body> <ABC:ABCSPGMOperation> <ABC:req> <ABC:plastic_number>1234</ABC:plastic_number> </ABC:req> </ABC:ABCSPGMOperation> </soapenv:Body> </soapenv:Envelope>[/code] The above is my input passed by the client. How can I extract the values within the tag 'ID','ConsumerTransactionId' and 'ABC:plastic_number' using simple xpath expressions. I know that if we give … Software Development xml | |
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++ | |
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 | |
[CODE]#include <iostream> using namespace std; class NumDays { private: double hours; double days; public: NumDays(double h=0) { hours=h; }[/CODE] [ICODE] how can I assign values to both hours and days, but only takes in the number of hours as its argument? I don't know how to assign the days without … Software Development c++ | |
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 … | |
Hey guys, in my programming assignment I need to split the mantissa and exponent and add them to two separate variables. so £1.88 would be [CODE] double amount = 1.88; //then after the conversion mantissa = 1; exponent = 88; [/CODE] I've looked at this a lot over the web, … Software Development java | |
Hello everyone! I'm fairly new to C++ and am having trouble with a "nested loops" problem. Here is the problem: USING A WHILE LOOP, get integers from the user. Then, USING A FOR LOOP, calculate a 'times table' of that number and the numbers between 1 and 20. When the … Software Development c++ | |
[CODE] var studienummerQuery = from members in dbcontent.Medlemmer.Include("Retninger") orderby members.Fornavn select members; foreach(var a in studienummerQuery) { Console.WriteLine(a); } [/CODE] Thats my code, wonder why it doesnt work.. My tables are: Medlemmer Retninger | |
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 ); … | |
hi i am making a 16puzzle game and i keep getting error about parameter conversion in main function. maybe someone can help me out and figure out whats wrong? i had this program written with functions and it worked perfectly,but now making it with classes(coz my teacher requires classes in … | |
Hello friends, I have a Customer class (Parent class) and Member class (child class which extends Customer class). the coding is like this [CODE] public class Customer { String name; } public class Member extends Customer { int memberID; } public class Tranasaction { public void printTransaction(Customer customer) { if(customer.memberID … Software Development java | |
Hello. I have a six locations checkboxlist and i'd like to create an array with the checked locations like this: [code] int[] v=new int[6]; private checkboxlist1_changed.....(...) { for(int i=0;i<6;i++) { if(checkboxlist1.getitemchecked(i)) v[i]=1; else v[i]=0; } } string w=v.Tostring(); [/code] and it seems it's always a step behind, cant figure it … Software Development | |
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 | |
so far the user can select a file that he want to open to be copied, is there a way of letting the user selecting multiple files to be copied to one file? i was thinking of looping around asking the user to add another file if the user wanted … Software Development c file-system | |
[CODE] #include <Windows.h> #include <iostream> #include <mysql.h> using namespace std; int main() { MYSQL *conn; char names; names= mysql_query(conn,"select * from names"); return 0; } [/CODE] error: Error 1 error C2440: '=' : cannot convert from 'int' to 'char *' i want to set a varuable for the query so … | |
delete(int list) { int i, j, row; char temp_last[max], temp_frst[max]; clrscr(); gotoxy(1,21); printf("Delete Data"); printf("\n-----------------"); gotoxy(1,23); printf("Last name : "); gets(temp_last); gotoxy(1,24); printf("First name : "); gets(temp_frst); /*for(i=0; i<=list; i++) { if(stricmp(record[i].last_name, temp_last)==0 && stricmp(record[i].frst_name, temp_frst)==0) { for(j=i; j<list; j++) { temp_last=record[j+1].last_name; /*<------Error on this . line */ temp_frst=record[j+1].frst_name; record[j].last_name=temp_last; … Software Development c | |
i need help with the following: make a program that would display the nth of the fibonnaci sequence. 1 1 2 3 5 8 13 21 34 55 ... n implement it using both iteration and recursion. Software Development c display programming-construct | |
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 … | |
[B]Hello all it's my first question[/B] [B]I am new to database with visual basic .... I am working on a application form that allow users to register log in and get a profile page .. the problem is i need a code of leting me printing data from the databse … Software Development visual-basic | |
Hello, as I learned conio.h header file is used in Windows not Linux, I found two things from the Internet 1. Linux c++ implementation of conio.h [URL="http://sourceforge.net/projects/linux-conioh/"]http://sourceforge.net/projects/linux-conioh/[/URL] 2. libconio [URL="http://sourceforge.net/projects/libconio/"]http://sourceforge.net/projects/libconio/[/URL] What should I do to use them? I am not very familiar with C++ and I couldn't find out myself.. … Software Development c++ | |
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 | |
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 | |
i have this code and its output is 54. my question is, can someone please explain to me the process of getting this certain output, which is said to be 54. thank you. :) [CODE]#include<stdio.h> #include<conio.h> int sumS (int n, int m); void main () { int x=2, y=5; clrscr(); … Software Development c | |
Hello, I am in a process of making an adventure text-based game and I was wondering if it's possible to change the text color on the go. What I mean is that normally, your text would be white, but when you advance in the story (e.g. advance on lines), the … Software Development | |
hello. I want to know if its possible to develop a mobile application using java language. Software Development java | |
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 | |
Here is the input.txt file that I have. [code]2 5 -2 3 1 2 4 0 1 2 1 0 [/code] These are 2 polynominals. 2x^5 - 2x^3 + x^2 + 4 and x^2 + 1 while <3,5> : 3 is the coefficient, 5 is the degree. I just can … Software Development c++ linked-list | |
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 |
The End.