Forum: C Sep 21st, 2009 |
| Replies: 7 Views: 456 For those who are lazy to search through internet here is the link: gets() vs fgets() (http://faq.cprogramming.com/cgi-bin/smartfaq.cgi?answer=1049157810&id=1043284351) |
Forum: C Sep 14th, 2009 |
| Replies: 7 Views: 856 I am greatly disappointed. |
Forum: C Aug 29th, 2009 |
| Replies: 4 Views: 367 All your code do is assigning each element of your matrix to -1 and then display them. It is no surprise at all that you did not achieve the assignment because you haven't figured or aren't willing... |
Forum: C Aug 5th, 2009 |
| Replies: 18 Views: 592 1. Why create this function when you can simply compare two characters with operator ==.
int Check_Characters(char s1,char s2) {
if(s1==s2)
return 1;
return 0;
} |
Forum: C++ Aug 4th, 2009 |
| Replies: 3 Views: 219 Sorting concept is simple: from the least to the greatest or from the greatest to the least. To do so, you need to do comparison. So, the magic trick is comparison-rule (which is greater and which is... |
Forum: C Aug 4th, 2009 |
| Replies: 7 Views: 394 Here is your code and its logical error.
int RemoveChars(char *S,char c) {
int i=0;
int spaces=0;
char temp;
for(i=0;S[i]!=0;i++) {
temp=S[i];
if(S[i]!=c) {
... |
Forum: C++ Aug 2nd, 2009 |
| Replies: 6 Views: 458 If you truly understand the concept of doubly-linked list, these problems would be very easy. Lets start with basic doubly-linked list concept. Doubly-linked list data structure consist of 3... |
Forum: C++ Aug 17th, 2008 |
| Replies: 14 Views: 1,780 Do as what Edward has said and you will able to solve your problem easily. You don't actually need integer to store number, you can just use string to represent the number. First of all, you create... |
Forum: C++ Jul 22nd, 2008 |
| Replies: 6 Views: 691 You might wonder why your problem hasn't been answered. It is obvious that you haven't use the code tag which make it very unfriendly to read your code. I recommend you to tag your code and post your... |
Forum: C++ Jul 22nd, 2008 |
| Replies: 24 Views: 64,304 Text-based Role-Playing Game Project (For Beginners)
Firstly, this game will start with an introductatory storyline of the game to attract player interest. Then, it asks a player to enter his or her... |
Forum: C++ Jul 17th, 2008 |
| Replies: 6 Views: 983 Of course you can have multiple of them. However, try to avoid using it as much as possible since most of the time goto can be replaced with a loop. For some case such as break multiple-level of... |
Forum: C++ Jul 16th, 2008 |
| Replies: 37 Views: 3,522 The first problem has been bothered me alot while I was doing my school-assignment so now I got a chance to solve it now. I think this problem can be solve by using mathematic.
Let say A is the... |
Forum: C++ Jul 16th, 2008 |
| Replies: 19 Views: 1,498 I think you didn't provide enough information about your project. For example: how the loop produce the combination? how will you compare those combination? what is the purpose of your combination?... |
Forum: C++ Mar 14th, 2008 |
| Replies: 30 Views: 10,352 My algorithm is a little bit different. First, I generate the random number into the array in order. Then randomly swap the array elements to make it disorder. For example: I want to generate 11... |
Forum: C Feb 14th, 2008 |
| Replies: 17 Views: 4,516 Not a good way :( but it works fine.
int sum(int num1, int num2)
{
int total, temp, temptotal;
total = num1 ^ num2;
for(temp = num1 & num2; temp != 0; temp = temptotal & temp) {... |
Forum: C++ Feb 14th, 2008 |
| Replies: 16 Views: 1,741 I believe the largest value that your code can generate is 499 :D |
Forum: C++ Jan 31st, 2008 |
| Replies: 8 Views: 997 For your redirecting question, you could use do...while loop:
do {
// input your code here
} while (x < 1 && x > 5); // If the input isn't in the range of 1-4, it will process the code in the... |
Forum: C++ Jan 26th, 2008 |
| Replies: 20 Views: 2,502 I don't feel that your code works 100% correctly. What's happen when the first digit is number 9? 9 < 9 == false. |
Forum: Geeks' Lounge Jan 25th, 2008 |
| Replies: 10 Views: 1,157 English: Welcome back!
Germany: Willkommen zurück
Greek: Καλως ηρθατε και παλι
Italy: Bentornato
Portuguese: Bem-vindo de volta
Russian Добро пожаловать обратно
Spanish Bienvenido de nuevo |
Forum: C++ Jan 9th, 2008 |
| Replies: 6 Views: 2,643 Within the range of 0 to 49. |
Forum: Geeks' Lounge Jan 7th, 2008 |
| Replies: 48 Views: 3,771 Believe me, I will be the richest guy in the whole world, if I was back in 1982.
1) I will bet alot alot of money in World Cup, Euro Cup, Asia Cup.
2) Be the first person to make Search Engine,... |
Forum: Geeks' Lounge Jan 2nd, 2008 |
| Replies: 22 Views: 2,304 Producing a good game, is not all about programming, but also producing a good sound effect, 2d art, 3d modeling, and writing. |
Forum: Geeks' Lounge Dec 30th, 2007 |
| Replies: 57 Views: 5,329 Anyone from Antarctica? He he |
Forum: C++ Dec 25th, 2007 |
| Replies: 4 Views: 597 More comments are needed to be added.
/*********************************
* What is the title of your program? *
* What is the purpose of this program?*
* Written by who? ... |
Forum: Geeks' Lounge Apr 7th, 2005 |
| Replies: 11 Views: 2,083 http://www.yagoohoogle.com/
check this out people |
Forum: Visual Basic 4 / 5 / 6 Mar 26th, 2005 |
| Replies: 6 Views: 8,668 you can't do it there no easy to set command button forecolor. but you can use CheckBox instead, set Style = Graphical (it exactly look like button) , and copy this code in
Private Sub... |
Forum: Visual Basic 4 / 5 / 6 Mar 23rd, 2005 |
| Replies: 2 Views: 10,641 this function will calculate a string formula which support cos, sin, log, abs, mod, and example : [10*2+(2+3)]/(5 mod 4) and you will get the answer, and this function it really easy to plugin with... |