Search:

Type: Posts; User: SirNot

Page 1 of 2 1 2

Search: Search took 0.01 seconds.

  1. Replies
    76
    Views
    31,851

    I made this probably a year ago or so, and to be...

    I made this probably a year ago or so, and to be honest I can't really be bothered converting it's interface to the specifications. however, it may be of interest: it can easily calculate >200000...
  2. Replies
    78
    Views
    21,322

    I skipped a lot, but- I love both classical...

    I skipped a lot, but-


    I love both classical music and electronic/trance (eg.) -- probably as far apart as you can get. Yet I have (conditional) offers to study math and physics from both...
  3. Thread: K&R solution?

    by SirNot
    Replies
    12
    Views
    3,014

    why even bother splitting it up into if/elseif...

    why even bother splitting it up into if/elseif cases. just use the fact that conditionals such as == and != represent a boolean value.

    ie. something like
    while((cond1) + (cond2) == 2) ...
  4. Replies
    3
    Views
    2,535

    david: http://keepvid.com/ EDIT: and here are...

    david: http://keepvid.com/

    EDIT: and here are a few funny ones I can think off the top of my head:
    - Mario and Luigi vs. Vice City
    - Fear of Girls
    - Worst Job
  5. Replies
    24
    Views
    3,956

    Well not everyone in the world needs a bajillion...

    Well not everyone in the world needs a bajillion features in the browser; I wasn't aware a 'world map plotter' was so incredibly essential in software meant to browse the internet.

    And on the...
  6. Replies
    24
    Views
    3,956

    A fresh Opera 9.02 install takes up a little more...

    A fresh Opera 9.02 install takes up a little more than 5 megabytes (5.33 on my disk, to be exact).
  7. Replies
    24
    Views
    3,956

    It's because Opera has so many more features to...

    It's because Opera has so many more features to begin with, most of which require plugins in firefox (see http://virtuelvis.com/archives/2005/01/opera-and-firefox-extensions and...
  8. Replies
    24
    Views
    3,956

    I would recommend Opera. It is smaller than...

    I would recommend Opera. It is smaller than firefox, faster, more efficient (from my experience at least; it's certainly not less efficient), is just as if not more standards compliant, and still...
  9. Replies
    13
    Views
    1,589

    If you want to use scanf then try something like ...

    If you want to use scanf then try something like
    scanf("%20[^\n]", surname); //where 20 would be the max length
    But using fgets would probably be the best option.
  10. You could use the backspace char ('\b') to erase...

    You could use the backspace char ('\b') to erase the previous character on the line.
  11. Replies
    14
    Views
    1,543

    You need to check the sign of the discriminant...

    You need to check the sign of the discriminant before attempting to get the square root of it, as you may be trying to take the sqrt of a negative value. Eg.
    d = b * b - 4 * a * c;
    if(!d)...
  12. Thread: Introduction

    by SirNot
    Replies
    12
    Views
    3,242

    Hello Surge, I'm SirNot (shortened version of...

    Hello Surge,

    I'm SirNot (shortened version of SirNotAppearingOnThisForum) and I'm a board lurker. I typically contribute little to nothing in help to these boards as there are so others who are...
  13. Replies
    2
    Views
    5,897

    Use the pow()...

    Use the pow() function for exponents, although in your case it's probably easiest to simply put radius*radius.
  14. Replies
    12
    Views
    8,161

    Well I was actually refering to your '

    Well I was actually refering to your '<' operator...

    And besides, you can still write the function without the assignment operator:
    unsigned long getbitmask2(unsigned long high, unsigned long...
  15. Replies
    12
    Views
    8,161

    Well this would work on a compiler which pads...

    Well this would work on a compiler which pads negative signed ints with 1s when shifted to the right:
    unsigned long getbitmask(unsigned long high, unsigned long low)
    {
    unsigned long out, sign, t...
  16. Replies
    12
    Views
    8,161

    Oops, I didn't see that part of the...

    Oops, I didn't see that part of the specification...
  17. Replies
    12
    Views
    8,161

    I'm probably assuming too much again somehow or...

    I'm probably assuming too much again somehow or other, but you could try
    unsigned long bitMask(unsigned long high, unsigned long low)
    {
    unsigned long out, t = ~0;

    out = (t << high) << 1;...
  18. Replies
    8
    Views
    4,431

    Sent mine

    Sent mine
  19. Thread: WireWorld

    by SirNot
    Replies
    34
    Views
    12,206

    Here's a shortened version of a binary counter...

    Here's a shortened version of a binary counter, if that's of any interest.

    delay = 10...
  20. Replies
    41
    Views
    4,046

    I didn't mean that I religiously try to avoid...

    I didn't mean that I religiously try to avoid using gotos, I do use them where I need to. To tell the truth, I don't really know what got me on to doing that, the general idea is the same, I guess I...
  21. Replies
    41
    Views
    4,046

    This may seem like weird thing to do, but I...

    This may seem like weird thing to do, but I personally like to use do {} while(0); loops when I have a decently sized procedure where an error could be encountered in several places, so I can easily...
  22. Replies
    12
    Views
    5,778

    I believe if an array element is not explicitely...

    I believe if an array element is not explicitely initialized it can be anything, typically what was already in that memory address.
  23. Replies
    15
    Views
    3,964

    Well, according to opengroup...

    Well, according to opengroup:



    Wikipedia probably isn't a bad place to start: http://en.wikipedia.org/wiki/Unicode
  24. Replies
    15
    Views
    3,964

    Just an idea, but if the file is unicode encoded...

    Just an idea, but if the file is unicode encoded something like that might happen.
  25. Replies
    25
    Views
    11,396

    Agh, alright, I admit, I've too many assumptions.

    Agh, alright, I admit, I've too many assumptions.
Results 1 to 25 of 45
Page 1 of 2 1 2