No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
17 Posted Topics
Re: Read up on scanf and try to understand what it means to catch an argument. I think if you change your scanf() line to: scanf("%d", &n); it will work for you. | |
Re: I don't have the same model VAIO that you do, but it does sound like you have a broken fan. The system probably has an override that shuts down when it gets too hot to prevent damage. You can disassemble the box and look at the fan. This will be … | |
Re: We have a policy of not doing people's homework for them. However, here are a few pointers to get you on the right track: 1. Understand types. What is a void? What is a char? What is a double? Once you understand types, which one seems most appropriate for mathematical … | |
Re: You'll get more help if you post your code, even if it isn't working yet. I don't even have any suggestions because the first part of your post makes it appear that you will be reading from a file, while the second part of your post makes it appear that … | |
| |
Re: I built the code and got the random value 4. So the knight tried to move from [4,4] to [5,6] to [7,8]. Since the board is defined on [0-7,0-7], this move is off the board. Which is the bug with your code. Doing the same move (i.e. up 1 over … | |
Re: I'm sure you already know what the problem is, but here is the Display() code: [CODE]void Display(fstream &information) { int Stock; cout << "Enter a Stock Number:"; cin >> Stock; information.seekg ((Stock - 100 ) * sizeof(stock)); stock storage; information.read (reinterpret_cast< char * >( &storage), sizeof (stock)); if (storage.getstock() != … | |
Re: Here are a few hints: Let's refer to a 2 dimensional array as a matrix. Let's say that in your example the matrix has 15 rows and 3 columns. When you want to loop through a 15 x 3 matrix, you would use something like: [CODE]for(row = 0; row < … | |
Re: I am making a bit of a guess here because you haven't posted all of your code, but I think you have declared something like: char binary1[length1]; Then you copy the linked list into the char array called binary1. Although you have asked for a specific amount of memory when … | |
Re: Just replace the i and j loops to call rand(). For example, in the multiplication loop change: [CODE] case 1: for ( int i = 1; i <= 12; i++ ) for( int j = 0; j <= 12; j++ ){ cout << "What is " << i << " … | |
Re: In your first constructor you are using a function, strcpy() to copy the contents of one string to another. Which works great because strcpy() takes two strings as arguments. In your second constructor you want to take a char and make a string (an array of chars) out of it. … | |
Re: You've declared tempage to be an int. So when you multiple 2 * .1 (for example, if the person is 30) you are getting 0.2. When this is stored as an int, it is stored as 0. You need to store the result of x * 0.1 as a floating … | |
Re: The BIOS should have an option to restore defaults. You might want to give that a try. | |
Re: If you want specific help, you should post what you've already tried to do (i.e. code) and what error or bug you are encountering. If it helps you to get started, strings in C/C++ are arrays of chars. You can compare an element of an array of chars to an … | |
Re: You didn't post any code so I am assuming you are just interested in general help. Check out string.h (they have a nice writeup on Wikipedia) which will give you some ideas about the kinds of string handling functions available in C. Good luck! | |
Re: Here are a few tips to address the error you are seeing: Understand that in C a string is an array of chars. So line and line2 are arrays of chars, and s and p are pointers to those arrays. Because p is a pointer to an array of chars, … | |
Re: I don't have the same model you do (I have the PCG-TR3AP), but I recently took mine apart and I thought that three of the screws were pretty tricky. Hopefully they used the same tricks on your model. There are screws under each of the back rubber feet. I just … |
The End.