Yup, XSquared, you were most right.
SomeClass *somearray[A_SIZE];
did the job right. I should've known better... I should stop reading and start coding, really. Thanks a lot.
Type: Posts; User: WarBaboon
Yup, XSquared, you were most right.
SomeClass *somearray[A_SIZE];
did the job right. I should've known better... I should stop reading and start coding, really. Thanks a lot.
I'm having a simple yet confusing problem. Say SomeClass is a class with lots of methods and fields and that uses multiple inheritance (could that be the problem ?):
somearray[index] = new...
Tsk tsk tsk... asking for help on another board, heh ? That's baaaaaaaaad.
Well visibly, I won't give any clues to you. But the only hint I could allow myself to give is : look into sockets.
...
Mucho thanks for that link. It's like my dreams came true.
Your code does work, with one slight change.
cout by itself means nothing. You'd have to either use std::cout for each time you use it, or adding using namespace std after your #includes.
EDIT...
Sorry, theOracle, even with your edit I have trouble understanding what you're looking for. Maybe the value of the RC constant ? Or the period ? Or maybe both ?
Not quite.
Vt = 12*pow(M_E,(t/RC))*sin((2*3.14159/P);
Don't forget to include cmath.h for the pow() function and the value of e, represented by M_E.
But I'm as confused as major_small : what...
Thanks for the help/code, everyone. And yes, I shall use the Search from now on, Quzah. :)
Here's my problem. Say you have a certain set of data, of which type is unimportant. For example's sake, let's use an array of 4 characters.
char array[4] = "abcd";
Now I want to create a program...
I've always had problems outputting special characters on screen (e.g. é, à, ü , ç and such), whatever the language, compiler, etc.
So, is there any way I could correctly print them on screen ?
Nope, even with the using namespace std line, I can't get it to work too. I'll go take a look on Dev's forums, thanks. (Or maybe simply get back to good ol' 4.6.9).
EDIT : Well, here it is :...
Yup, C++ for dummies is an excellent book, even for those who don't have a clue about what is a compiler. I learned C++ from that book, too.
The following should work for Dev C++ (well, it did work for me,heh).
#include <cstdlib>
#include <iostream>
#include <ctime>
using namespace std;
int main() {
srand(time(NULL)); //...
You might be interested in using rand() and srand() instead, if nothing works.
What I meant is that the pseudorandom number you will find will most likely not be exactly one of your t's. You will need to find the value that is closer to the value you get. I admit that that...
A lot of people might be familiar with Poisson's Distribution - much like me. Those with some statistics knowledge might want a short explanantion : go to...
I won't do it for you, but a simple algorithm for Pi calcution is as follows :
Pi = 4 - 4/3 + 4/5 - 4/7 + 4/9 -... you get the idea. Have fun with this Fourier series.