Thursday, September 1, 2011

Facebook under attack!!!

Hi~ long time no XD

anyway, i'm so excited to see what's going to happen to facebook. Anonymous are so interesting lately. They announced they're going to smash facebook underground. Personally for the time being it's a bit expected to succeed hacking facebook but some people would think like ... come on it's facebook impossible to hack it. but wait, SONY was hacked and some other websites were also hacked by anonymous. so would you re-think about it? XD
anyway there's a poll over there on the right to see what most of you has in mind.

peace & all good stuff~

=)

Saturday, August 6, 2011

One of the good articles talking about 'How To Become A Programmer'

It's simply one of the most usefull articles I've ever read in Programming field.
I would love to share it:
http://www.arabic-os.co.cc/2011/08/blog-post.html

peace and all good stuff~

Wednesday, August 3, 2011

Do you want to share? =D

I've got a book called 'C Programming: A Modern Approach', it's the text book students of C Programming use for refering. Since weeks back I've been reading this book to recall my knowledge in C and trying to catch some more information & experience. The main point now is 'Arrays section'. I've never learn arrays in C. I was only dealing with arrays in Java and they really look much nicer in Java than in C lols..
Anyway, there is a problem I was hitting on since couple of days and til now there is no answer.

let me show it to you:
/* Checks number for repeated digits */
#include<stdio.h>

#define TRUE 1;
#define FALSE 0;

typedef int Bool;

main()
{
    Bool digit_seen[10]={0};
    int digit;
    long int n;

    printf("Enter a number: ");
    scanf("%d", &n);

    while (n > 0)
    {
        digit=n%10;
        if (digit_seen[digit])
            break;
        digit_seen[digit] = TRUE;
        n /= 10;
    }

    if (n > 0)
        printf("Repeated digit\n\n");
    else
        printf("No repeated digit\n\n");

    return 0;
}

To be honest I spent a long period to understand that code. I didn't start solving the problem until I got the idea about it =D
anyway, I want to share the question with you guys, I think it's fun for all of us to think and try to come with a solution or an idea about how the answer code will be.

Here's the exercise:
Modify the repdigit.c program (The above program) so that it shows which digits (if any) were repeated:
Enter a number: 93977
Repeated digit(s): 7 9

didn't figure it out yet but I'm still trying. Here's what I went through so far:
#include<stdio.h>

#define TRUE 1;
#define FALSE 0;

typedef int Bool;

main()
{
    Bool digit_seen[10]={0};
    Bool repeated_digit[10];
    int digit;
    long int n;

    printf("Enter a number: ");
    scanf("%d", &n);

    while (n > 0)
    {
        digit=n%10;
        if (digit_seen[digit])
            {repeated_digit[digit]=digit;
            }

        digit_seen[digit] = TRUE;
        n /= 10;
    }

    if (repeated_digit[digit])
        {printf("Repeated digit\n\n");
        printf("%d", repeated_digit[digit]);}
    else
        {printf("No repeated digit\n\n");
        printf("%d", n);}
    return 0;
}
it's a wrong answer and I've been changing it from the beginning to now =D

enjoy it =)

peace~

Tuesday, June 28, 2011

Linux!!!

Hi, how are you? =)

I have something new on my laptop, it's Linux operating system =D
I've installed Ubuntu version and there was a variety of fails before I reached my Desktop there XD . Now I'm writing this post over ubuntu =)
I was really impressed by the set of softwares, both embedded and available to download. Some examples: LibreOffice, internet messenger, media, firefox and more.
I liked a property that's called 'Workspace switcher'. It's really nice benefit of the system, where user can easily switch among the applications running at a session.

Here is a screenshot: XD
And, you can very easily take a screenshot by just one step. Hit the Printscreen button(PrtSc) and you're done. Name it and save it.
I loved the system I really did. May I mention that it's very very simple?!
Almost forgot, if you liked to try it without installing, YOU CAN. Linux is unbelievable isn't it?XDDD

peace and all good stuff~

Monday, May 23, 2011

It's starting again!

The feeling when I don't know what to do or where to go next!
I was kind of lost the last few weeks, where nothing appears good to me. I supposed to keep working on Java because that's what I was wanting to. But eventually everything seemed to be non-worthy. I need some refreshing I think.

I was reading this page today: http://www.cprogramming.com/whyc.html am I going back to C programming? Maybe

peace~

Sunday, May 8, 2011

Wednesday, April 27, 2011

sorry!!!

sorry for not posting anything lately
i don't know what i'm going to do next =(