Forum: C++ 1 Hour Ago |
| Replies: 1 Views: 20 Two question the first it why are you using goto? It is very bad practice and your noticing first hand the negative effects it can have. Secondly why haven't you just used a while loop instead of all... |
Forum: C 19 Hours Ago |
| Replies: 11 Views: 150 Post the whole program so that we can take a look. |
Forum: C 23 Hours Ago |
| Replies: 7 Views: 207 Try Code::Blocks or Bluefish.
IMO Code::Blocks is better, since Bluefish started life as web development IDE.
Alternative is downloading notepad++ and also gnu compiler package. |
Forum: C 23 Hours Ago |
| Replies: 11 Views: 150 Once you have scanned the input in you need to use strcpy() to copy the string from the variable to the data structure variable.
strcpy(inventory[num+parts].name, part_name]; |
Forum: Java 2 Days Ago |
| Replies: 2 Views: 113 Thanks a lot the printstream worked wonders. |
Forum: Java 3 Days Ago |
| Replies: 2 Views: 113 Hey,
I want to know whether it is possible to send a formatted string ie.
System.out.printf("%2d%6d%23f...",a,b,c);
to a .txt file so that when I view the .txt it will appear properly... |
Forum: Java 6 Days Ago |
| Replies: 4 Views: 173 I checked both the filename and the class name are the, this is a very strange bug.
hello.java:11: cannot find symbol
symbol : class string
location: class hello
public static... |
Forum: Java 6 Days Ago |
| Replies: 4 Views: 173 Hi,
I'm having a rather strange problem with the Java compiler.
I'm trying to compile a simple hello world program and I can compile it perfectly within NetBean but when I try to use the... |
Forum: Computer Science 6 Days Ago |
| Replies: 4 Views: 309 Take about going from 0 -> 100 in 0.0 seconds :D |
Forum: C++ 6 Days Ago |
| Replies: 5 Views: 164 Hey,
A couple of questions, what compiler are you using and how in the world does this run?
I can see two changes that you have to make off the bat, first replace
#include<iostream.h> with... |
Forum: C 6 Days Ago |
| Replies: 12 Views: 493 It isn't all that hard:
-- declare a variable to hold the first letter
-- make a loop that has 25-26 iteration (depends on how you design the loop)
-- print the variable
-- increment the... |
Forum: C 7 Days Ago |
| Replies: 4 Views: 292 I glimpsed at you problem and I'm not sure why you would use recursion when a loop is better and easier. |
Forum: C 7 Days Ago |
| Replies: 3 Views: 262 Maybe you need to compile in c++. |
Forum: C++ 34 Days Ago |
| Replies: 3 Views: 147 Comments are ignored by the compiler. |
Forum: Python Aug 11th, 2009 |
| Replies: 2 Views: 164 Hi,
I have slogged my way through, Mark Lutz's Learning Python it is a great book but the problem I have with it is that it doesn't have any practical programing question like the dietel books.... |
Forum: Computer Science May 26th, 2009 |
| Replies: 4 Views: 510 If you plan on studying python get this as well.
http://www.swaroopch.com/notes/Python |
Forum: Computer Science May 26th, 2009 |
| Replies: 3 Views: 350 |
Forum: C++ May 24th, 2009 |
| Replies: 9 Views: 316 Um..."while" and "for" come to mind, just need to use a little creativity. Its not that hard. |
Forum: C May 22nd, 2009 |
| Replies: 9 Views: 439 I don't think that there is a right or wrong in psudo code, unless ofcourse your doing something really stupid in it. |
Forum: Perl May 21st, 2009 |
| Replies: 5 Views: 445 Trust me, this is the best place to get help. Especially for such a simple problem. |
Forum: Python May 21st, 2009 |
| Replies: 5 Views: 386 I agree about good style, I'm going to start cracking the books. Thanks a lot for the advise and links. |
Forum: Python May 20th, 2009 |
| Replies: 5 Views: 386 Thanks a lot, I did find the website on my search for python 3 notes although I never really took the time to look into it, going to start it now. |
Forum: Python May 20th, 2009 |
| Replies: 5 Views: 386 I bought a bunch a cheap books on Python and am wondering whether I should read them as Python 3 introduced changes to the language and so to speak broke old code as far as I can tell.
I am... |
Forum: Perl May 19th, 2009 |
| Replies: 4 Views: 989 Try the LWP module, its clean and highly efficient, you just need to make sure that you put in checks to see that you receive the proper data. |
Forum: C May 16th, 2009 |
| Replies: 4 Views: 560 Alternatively download and use Code::Blocks IDE or Visual Studios Express both are excellent alternatives. |
Forum: Perl May 13th, 2009 |
| Replies: 5 Views: 844 This is what I came up with, but it seems to be repeating the first match rather than check for the next meta tag.
my (@m) = $d =~ m/(<meta (.*?)>){1,5}/is; |
Forum: Perl May 13th, 2009 |
| Replies: 5 Views: 844 Thanks that worked great.
What exactly does /is do? Also one more question if I try to extract the meta tags and place each individually in array will it work? Assuming that their maybe 1 or meta... |
Forum: Perl May 13th, 2009 |
| Replies: 5 Views: 844 UPDATE:
I managed to get the data into one string and now I am trying to match with a regular expression.
I am having trouble with the regular expression.
my $d = ($s =~... |
Forum: Perl May 13th, 2009 |
| Replies: 5 Views: 844 Hey,
I have used the LWP:\:Simple module and saved the source of a website in a file. I am trying to extract all the data between the <head> tags and pass it to a variable to process.
So far I... |
Forum: C++ May 12th, 2009 |
| Replies: 3 Views: 397 This seems to work as the data is copied.
TextFieldLoader::TextFieldLoader(/*const */char *fn, int row, int col, int width, int height)
: fstream(fn), TextField(fn, row, col, width, height){... |
Forum: C++ May 12th, 2009 |
| Replies: 3 Views: 397 A little update, I think its wrong as the data sent to TextFieldLoader::TextFieldLoader(/*const */char *fn, int row, int col, int width, int height)
: ifstream(fn), TextField(fn, row, col, width,... |
Forum: C++ May 12th, 2009 |
| Replies: 3 Views: 397 Hello,
This is for an assignment I have to do, I have completed most of it just can't get one part to work correctly.
The assignment is:
The TextFieldLoader class will have only one... |
Forum: C++ May 7th, 2009 |
| Replies: 5 Views: 533 Why is it then that I'm able to compile the program when my main is a part of the screen.cpp file instead of the main.cpp? |
Forum: C++ May 7th, 2009 |
| Replies: 5 Views: 533 The above should be:
Also please note that the variables mentioned in the errors are not used at all in a2main.cpp they were defined in console.c then redefined in screen.cpp, but declared in... |
Forum: C++ May 7th, 2009 |
| Replies: 5 Views: 533 Hey,
I have a program that has 5 files, 2 header files called:
console.h
screen.h
and 3 source files called:
a2main.cpp |
Forum: C May 3rd, 2009 |
| Replies: 4 Views: 527 Huh? I'm sorry but what exactly is your question? you have given a set of statements with no question. |
Forum: C May 3rd, 2009 |
| Replies: 3 Views: 339 Please use the code tags properly and preview your post.
And run your program and see what comes up, at a glance it seems ok.
PS. remove the \ in the code tag I have shown. |
Forum: Python May 3rd, 2009 |
| Replies: 4 Views: 355 Thank you for your reply.
If I understand correctly nonlocal will take the value defined in func_inner() and pass it the variable x in func_outer().
Within the code for func_outer() after I... |
Forum: Python May 2nd, 2009 |
| Replies: 4 Views: 355 Hello,
I need some help understanding the nonlocal variables and functions. Currently I'm reading "A byte of Python" to ease myself into the language, which so far seems to be fairly... |
Forum: C Mar 25th, 2009 |
| Replies: 1 Views: 689 Managed to figure it out, all I needed was to create an index.
/* Trying to print a string from an offst using pointer arithmatic */
#include<stdio.h>
int main(){
char words[100] = ("This is... |