Sorry that I sounded like I was blaming sizeof. But I just meant sizeof may get you if you don't have profound understanding of it. :). I like the idea of passing the argument though.
Type: Posts; User: vincent01910
Sorry that I sounded like I was blaming sizeof. But I just meant sizeof may get you if you don't have profound understanding of it. :). I like the idea of passing the argument though.
Hey,
You have two issues in your code.
1. Getting 10 times bigger numbers: You need to properly end user input with '\0' in getNumber function because atoi will look to it to determine the end...
I've been using tcc on Windows xp for small programs and it's working fine in the sine case. And in its doc it claims float is being supported. Not sure about Vista though. Anyways it's not so hard...
You sure ur posting the code that prints this?
printf("y = %f\n" y);
This line won't even compile.
Epy you were right. After I changed that function declaration to
unsigned long long f(unsigned long long i)
It went on without a problem and I got the right answer.
Thank you guys for...
Thanks Epy. These are really good suggestions.
I updated code according to these.
#include <stdio.h>
int f(int i);
int main()
{
Hi,
I'm trying to solve this problem from Project Euler. Here's the problem.
The following iterative sequence is defined for the set of positive integers:
n → n/2 (n is even)
n → 3n + 1 (n...
Thanks laserlight. I get it now.
Thank you guys for reply. Still i have a question.
So King Mir what do you mean by "It does not include any arguments."?
In my understanding char *(*func)(char *) is a pointer to function that...
Hi,
So I have three similar working functions:
char *ltrim(char *);
char *rtrim(char *);
char *trim(char *);
Although i don't quite get the picture of the Boost library you're talking about, but i will give it a try when i’m no longer a newbie...
One of those things...
Now i totally understand. Thank you indeed for your detailed explanation, Mats, really helpful.
Thanks a lot matsp.
Your method %I64u produces correct result. But i just don't get it why %llu doesn't work. I've actually seen this usage somewhere...
Thank you grumpy for your reply.
I just copied the code from the editor to the board and added the comments. I think they are the same.
For the format specifier i used %llu for unsigned long long,...
Hello,
When i was playing with ULLONG_MAX, i wrote following code.
#include <stdio.h>
#include <limits.h>
int main()
{