199,124 Archived Topics
Remove Filter ![]() | |
Hi all. I need some help counting specific numbers in C. The programme should accept two sets of numbers. It should then count how many of the second number is in the first set. For example: First input = 23387 Second input = 3 Ouput = "Number 3 appears twice … | |
Code 1 [code] class Drink { public: Drink( char *name_ ) : name( name_ ) {} char *name; char get(int i) const { return name[i]; } }; [/code] Code 2 [code] class Drink { public: Drink( char *name_ ) : name( name_ ) {} char *name; char & get(int i) … | |
hi, I've been staring at my program code forever now and I'm going in circle. I don't know what I've done wrong. Can anyone please help? I'm supposed to design a month class that the following private members: 1) name: a MyString object that hold name of a month such … | |
[code] //Clifton Copeland //Excercise 6.27 //This program outputs Fahrenheit and Celcius range charts. //C = (F-32)*5/9 //F = C*9/5+32 #include <iostream> using namespace std; int cTable; int fTable; int main() { cout << "Choose which table you would like to display." << endl; cout << "Press C for conversions to … | |
For some reason this code is not correctly displaying the output....Is it a compiler issue? I'm not getting any affect from the width method, nor from the fill method. However, when I include <iomanip> and make a call to setw(int) then it works, but this code doesn't: Code: #include <cstdlib> … | |
Hello, anyone familiar with ansiString? Have a problem involving a string "1 1", should read "11". I want to get rid of the space in the middle. Can't change it to a character string or std::string so that isn't an option. Will i have to compare each character inturn with … | |
Hello, I've been reading Narue's Timesaving Tips and found this code from Dave Sinkula [code] #include <iostream> #include <vector> #include <iterator> using namespace std; int main() { int a[] = {1,2,3,4,5}; vector<int> v(a, a + 5); vector<int>::const_iterator it, end = v.end(); for (it = v.begin(); it < end; ++it) { … | |
Hiya I keep having this probelm with my script Basically I want it so when you click a command button some text shows up in my text box now I know how to do this but it does not seem to word wrap if I have a lot of text … | |
my site is working on internet explorer nicely but my site is not working on mozilla. pls any body help me | |
This is probably a stupid question, but i dont get the answer. Plz help me understand. Question: How could a linked list and a hash table be combined to allow someone to run through the list from item to item while still maintaining the ability to access an individual element … | |
![]() | Hello everyone! I am looking to embark on a project to develop a new content management system! The system will be very much like a portal, and I am looking for volunteers! If you are interested in helping out, please visit the project's community website at [url="http://keefe.hyspex.com/cms"]http://keefe.hyspex.com/cms[/url] I would also … |
Hi all, I am trying to check String field if it is null or not to excute some commands. But it is not working ... any help pls ?? String foryear = request.getParameter("foryear"); String decreeno = request.getParameter("decreeno"); I've tried to use : if (decreeno.length() > 1) sqlstr = sqlstr + … | |
How good do you have to be in C++ / C in order to enter the world of Open GL? | |
Hi :o , I would like to know if it is possible to write a console program in [B]MS Visual C++ 6.0 [/B](ATM transaction program), that stores data to a database such as [B]MS Access 2002[/B] or [B]Oracle 9i[/B], through [B]ODBC[/B] :?: I've searched all over the net and I … | |
Hi all, this question is for liberty basic (not sure if its the same or simmiler) but i am desperate for help :cry: it opens a txt file and reads the records the layout of the file is like this : HEN01023025,Jane Henderson,10/02/1982,Maths,67 HEN01023025,Jane Henderson,10/02/1982,Science,24 i have started a program … | |
How do i access or call system commands (can't really think of a better thing to call em???) for example on explorer you can right click on an object and select eject, or format ect ect (mainly eject is what i want to know about) any help would be greatly … | |
I'm writing a basic piece of code to perform a successive approximation algorithm, however, when it runs the approximation loop, it seems unable to distinguish between a positive and a negative number in that it runs both if statements. The code is shown below, and if someone could point out … | |
Hey everybody, first new thread for me on this forum. Just noticed that there's no posts here involving wxPython, I'm just curious to hear if anybody knows why that might be? Anyway, I've got some projects in the works that use it and I'll be happy to post some code … | |
I have read the tutorial about Python and JPEG here, but there si no mention about showing the actual picture! | |
Hello All, I am trying to convert structures to Byte stream(Serialization). I have one concept, Now I am converting each structure object to char pointer, but for structures with pointers this logic wont applicable. can any one help me with any logic for serialization in C/C++ | |
Hello, I am having a problem with %. I am trying to find all the years from 1628 to 2005 that are divisible by 15, so I did this: [CODE] if((year % 15 == 0) || (year % 100 == 0) || (year == 2005)){ System.out.println("Print something"); } [/CODE] So … | |
1. I am using strtok() and am storing the return value into a char array. eg. char word[]; word = strtok(file[][], " "); Do I need to initialize 'word' to a constant size before using it? The thing is I don't know how big the string from strtok is going … | |
I wanted to use the a far pointer in my program the declaration was like this char far* ptr; but when I compile the program the compiler gives error message that far undeclared, can any one help me in this regard how to use near, far, and huge pointers in … | |
[php] #include <iostream> using namespace std; typedef struct Template { int a; Template * link; // goes forward (one way reference) } list; typedef list * listptr; int main() { listptr head; // head is a type listptr listptr p ; listptr next ; head = NULL; //therfore make it … | |
[code] # include<stdio.h> void main() { int p; p = (1,2,2,100,1); printf("%d",p); } [/code] I dont know what will be the output . Can anyone please tell me what exactly second line implies ?? :rolleyes: | |
[B]Intro[/B] In part 1 we learned mostly about the header of the JPEG file. In this part we get to display the image and also extract and show any embedded comments. [B]wxPython[/B] To display the image we use wxPython. The raw JPEG image information is first pushed into a data … | |
hello everyone, i think im going to ask a very silly and noobie question but here it goes. im using VB 6.0 and im trying to create a program that would detect keypresses over another program. then automatically press something else for me say if i press f12 it should … | |
Code compiles w/o error but print function does not pull data from base class. I have looked over the chapter numerous times. This is a long one, sorry [code] class extClockType: public clockType { public: void getTimeZone(int& timeZone); void setTimeZone(int timeZone); void printTime() const; extClockType(); extClockType(int hours, int minutes, int … | |
I've just started using C++ for my engineering course. I downloaded the Dev-C++ compiler and I am having trouble with the cout command. Everytime the compiler outputs a value/ sentence etc, the command prompt shuts down before anything is displayed. I am running the program on XP Pro Does anyone … | |
We have a struct defined as : typedef struct tagWINDOWPOS { /* wp */ HWND hwnd; HWND hwndInsertAfter; int x; int y; int cx; int cy; UINT flags; } WINDOWPOS; Then we are sent a message... WM_WINDOWPOSCHANGING WPARAM wParam LPARAM lParam; Parameters wParam This parameter is not used. lParam Pointer … | |
hi, if some site uses this code [PHP] <script language="JavaScript"> var url = "http://www.aaaa.com"; var wh = 'width=250,height=250'; var time = 10; ////////// var winopop; window.onload = function(){ winopop = window.open(url,'news',wh); winopop.focus(); window.setTimeout(function(){winopop.close()},time*1000); } </script> [/PHP] they can open the site [url]http://www.aaaa.com[/url] in a window for 10 sec and then … | |
Is it right to say that....since arrays are passed by address automatically...so there's no need and reason to return arrays from functions(Is that the reason why it is not allowed in c/c++) | |
Sothink designs lots of new menu templates or samples. [URL=http://www.sothink.com/campaigns/dhtmlmenusample.php3]http://www.sothink.com/webtools/dhtmlmenu/samples/index.htm[/URL] | |
[COLOR=Teal]I have newly developed this app which may be quite useful to multiple domain owners. [B]EasycPanel[/B] The easiest way to manage multiple domains without any cPanel knowledge. Have all of your domains accessible on one screen - No more repeating those tedious cPanel logins - You can access the most … | |
i know it is possible to use python with c/c++ but can python be used similairly with c#/vb? | |
I'm trying to put together this program that creates a for loop but my end result is not positioned the way I need it like this but flipped around so it looks like a christmas tree effect. * ** *** **** ***** Please help I'm still learning and I can't … | |
i want to shift my database from one site to another . how i have to proceed. can anybody help me. | |
Okay I have a problem where the name of my vector is highlighted in yellow throughout my code and my output. I changed the name of the vector but on the output the word list is still highlighted in yellow, why? Below is my code: [code] #include <iostream> #include <string> … | |
This is in VC++.NET. I dynamically create the number of buttons the user specifies. I add these buttons to an Arraylist. The buttons names goes from b1 ..bn where n is the max num of buttons. The user will provide me the button number and the text to be added … | |
Hi, I'm currently writing a basic program (only been using Java for 3 weeks), and am trying to locate the "index position" of the first number in a string. For example String = "slow by 10.40s" or "fast by 1m2.2s" and want to use a method that returns me the … | |
hi i need some help with doing screen dumps or print screens in turbo pascal. when i press the print screen button whilst my program is running and then go and paste it in word, powerpoint or paint, all that pastes is the text and boxes i have created but … | |
Hi All, I am reading a textfile and ready to import into an access database. The issue that has just arisen of hidden characters in line of text. The file is sent to us by a third party. e.g. Problem_Details: all the objects were all very soft and were split … | |
I need to create a JAVA Class TicTacToe program. There are API doc of the class TicTacToe and TicTacToeApp.java which program control TicTacToe game play. Would you please tell me how to write the Java Class program. Thanks a lot! TicTacToeApp Java Program as shown below: /** * TIC TAC … | |
Program a student uses the computer to figure out his average in this class. As long as he enters grades between 0 and 100, it computes the average. If he enters -1 for a grade, it stops computing and prints out the average. I need help please someone help me … | |
well hi guys new to the forum and i need some help im writing a program where a guest’s name is entered and then assigned to a room. The motel has three floors and 30 rooms thus im using a 2D array (arr[3][10]) its supposed reserve a room and the … | |
Is there a good way to invert dictionary so key:value gets to be value:key? | |
I wondered if someone knew how to make a binary counter with vb? | |
sorry about my post on pygame, but i'm having more trouble. frist off im ending the simple program that opens a window with if event.type == QUIT: raise SystemExit That makes a window pop up asking me if i want to quit. Is there another way to exit the window? … | |
Can anybody in this forum page help me on getting example source codes like these ones: Any network game on Turbo C (2.01, 3.00)somethin' like that (with a filename extension of *.c) and any maze program on turbo C++ (with a filename extension of .cpp) if anybody would be able … |
The End.