Forum: C++ Jun 26th, 2008 |
| Replies: 9 Views: 4,998 How would I add it in with Code::Blocks? I can't figure it out |
Forum: C++ Jun 25th, 2008 |
| Replies: 9 Views: 4,998 How can I change my program's icon for anyone who uses the program? Obviously I would have to include the .ico file with it, but beyond that, I'm stumped. |
Forum: C++ Jun 23rd, 2008 |
| Replies: 3 Views: 392 I've been looking over classes, but I just can't understand a few things.
1) Why would you make variable private and use functions to set and read them? Whats the benefit?
2) Since I don't know... |
Forum: Getting Started and Choosing a Distro Aug 23rd, 2007 |
| Replies: 3 Views: 988 I want to download Fedora (Red Hat) Linux, but there are a ton of files on the websites. Do I download some? one? all? Is there a way to download them all without clicking all of them? And then,... |
Forum: C Aug 20th, 2007 |
| Replies: 6 Views: 955 Good god that is long, but it looks useful thanks! |
Forum: PHP Aug 20th, 2007 |
| Replies: 6 Views: 1,265 There are no invalid e-mails, and I found that if I hard code it, it will work. However I can't hard code it for what I'm trying to do, so anyway I can fix it? |
Forum: C Aug 20th, 2007 |
| Replies: 6 Views: 955 I understand what pointers are, but I don't understand why they are useful. I have read many tutorials about pointers, and yet I still don't know why someone would want to use one. Could anyone... |
Forum: PHP Aug 18th, 2007 |
| Replies: 6 Views: 1,265 I'm trying to mail a newsletter to a list of people, but I get an error every time it tries to mail. Anyone know what I'm doing wrong?
<?php
$file = fopen("upload/newletter.html", "r");
$sub =... |
Forum: PHP Aug 6th, 2007 |
| Replies: 5 Views: 677 I populated the array with a loop, that read the names from a text file. I tried doing it manually, and it worked, but I cant do it that way for what I'm doing. @Ezzaral: What is foreach()? Would... |
Forum: PHP Aug 5th, 2007 |
| Replies: 5 Views: 677 I'm trying to email to an array of subscribers to a weekly newsletter. Whenever I try though, I get an error "Bad parameters to function mail()". Heres the loop I'm using to mail:
$x = 0;
$y =... |
Forum: C Jul 22nd, 2007 |
| Replies: 10 Views: 2,189 Ok it works now. I use both your suggestions by changing the declaration and the call, thanks! |
Forum: C Jul 22nd, 2007 |
| Replies: 10 Views: 2,189 I'm trying to pass an array to a function for use, but it won't compile, it gives me the error:
>Type error in argument 2 to 'getMove'; found 'int' expected 'int *'
It is an int array, and it... |
Forum: C Jul 22nd, 2007 |
| Replies: 4 Views: 1,194 Well, right now its just a text console program I want to give to my friend. Can you please tell me how to do this from Dev C++? Any help would be great, thanks! |
Forum: C Jul 22nd, 2007 |
| Replies: 4 Views: 1,194 I'm using Dev C++, and I want to compile my program into a program usable on macs. Can I do this from Dev C++, or do I have to use a different program? |
Forum: C Jul 13th, 2007 |
| Replies: 10 Views: 2,731 Pelles C. Its a good IDE, similar to Dev C++. I don't know how to convert from type to another anyways... |
Forum: C Jul 13th, 2007 |
| Replies: 10 Views: 2,731 Its ok, I switched to a new IDE and it solved the problem. Thanks for the help guys. |
Forum: C Jul 13th, 2007 |
| Replies: 10 Views: 2,731 My compiler won't pause on getchar();. I have Dev C++ 4.9.9.2 and if I put getchar(); at the end of the program, it doesn't stop, and the console window still exits. It still exits when I assign a... |
Forum: C Jul 9th, 2007 |
| Replies: 6 Views: 2,553 Ok, I see what I was doing wrong. Thanks for the help. |
Forum: C Jul 9th, 2007 |
| Replies: 6 Views: 2,553 I'm trying to write a program to reverse a string, letter by letter. This was my latest attempt:
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int main(void)
{
char... |
Forum: C Jul 8th, 2007 |
| Replies: 3 Views: 889 Windows, but I know that it takes a lot of memory to execute system commands, and there not portable. |
Forum: C Jul 8th, 2007 |
| Replies: 3 Views: 889 If its bad to use system("PAUSE");, then is it bad to use any system commands? Such as system("title x"); or system("color 4f");? If it is, is there another way to title the program? |
Forum: C++ Jul 8th, 2007 |
| Replies: 47 Views: 8,593 Ok, I'll work on mastering C for now, thanks. |
Forum: C++ Jul 8th, 2007 |
| Replies: 47 Views: 8,593 Ok. I know some C/C++ right now, and no Java. |
Forum: C++ Jul 8th, 2007 |
| Replies: 47 Views: 8,593 I tried searching the forums for this, but couldn't find anything.
If I were to make a career out of computer programming, which would be better to learn, Java or C/C++? |
Forum: C Jul 5th, 2007 |
| Replies: 4 Views: 985 Often in a code snippet, I will see
printf("%d %2d %3d", i,i*i,i*i*i);
What does putting the numbers in front do, since it works the same without them? (ie)
printf("%d %d %d", i,i*i,i*i*i); |
Forum: C++ Feb 3rd, 2007 |
| Replies: 2 Views: 1,308 I wrote this code to produce a fibonacci seqeunce to a cretain number. However, when you get to a certain number, it starts producing negative numbers, and I don't know what to do.
#include... |
Forum: C Jan 31st, 2007 |
| Replies: 1 Views: 798 I want to use a function to get either the number of seconds or milliseconds since midnight, it doesn't matter. Does anyone know of a function that would give me this? |
Forum: C++ Jan 30th, 2007 |
| Replies: 5 Views: 2,356 #include <iostream>
#include <fstream>
using namespace std;
int main()
{
string sString;
ifstream File("file.txt");
File >> sString;
cout << sString << endl;
system("PAUSE"); |
Forum: C++ Jan 30th, 2007 |
| Replies: 5 Views: 2,356 The error is a windows error where it says the application encountered an error, and you can send a report or not. As for the cString, I've never neede to intialize it before. Also what library has... |
Forum: C++ Jan 30th, 2007 |
| Replies: 5 Views: 2,356 I'm starting to learn C++, and I wrote this program as a test:
#include <iostream>
#include <fstream>
using namespace std;
int main()
{
char *cString;
ifstream File("file.txt"); |
Forum: C++ Dec 5th, 2006 |
| Replies: 1 Views: 1,412 I am trying to write a program that allows the user to enter an ID number, and then the program opens a txt file with the ID information, but the ifstream part isnt working, I know its because I put... |
Forum: C Nov 21st, 2006 |
| Replies: 6 Views: 1,317 Nevermind, SOS was right, the problem was because it was 1 going in, sorry :( |
Forum: C Nov 21st, 2006 |
| Replies: 6 Views: 1,317 Please post a sample run of your program with input data as well as the answer.
Alright i tried with 2 numbers and this is how it went:
So i thought it was just backwards so i tried... |
Forum: C Nov 21st, 2006 |
| Replies: 6 Views: 1,317 Even though its one, it should be fine, because
trks++;
scanf("%d", &alnms[trks]);
will store it in alnms[1] then 2 etc. so it shouldnt affect it. Anyways, the problem is it... |
Forum: C Nov 21st, 2006 |
| Replies: 6 Views: 1,317 I keep looking at this code, and cant find out the problem...
I made this as part of a library of math functions. It asks the user to enter the number of numbers to subtract, then enter them. It... |
Forum: C Nov 19th, 2006 |
| Replies: 4 Views: 1,514 I changed that and now it just freezes after 2 inputted numbers... |
Forum: C Nov 19th, 2006 |
| Replies: 4 Views: 1,514 I cant get my function code to work. Its should return an average of however many numbers are entered, but it always returns 775863 no matte what... can anyone tell me whats wrong?
#include... |