Advertising (This ad goes away for registered users. You can Login or Register)

10 Days of Basic Programming: Discussion and Help

Discuss about your favorite (gaming...or not) devices here. The most popular ones will end up getting their own categories
Programming discussions for your favorite Device
Forum rules
Forum rule Nº 15 is strictly enforced in this subforum.
User avatar
Acid_Snake
Retired Mod
Posts: 3099
Joined: Tue May 01, 2012 11:32 am
Location: Behind you!

10 Days of Basic Programming: Discussion and Help

Post by Acid_Snake » Thu Mar 19, 2015 12:50 am

So I have opened this thread for those who want to discuss my series of 10 Days of Basic Programming. If you have any questions or need more personalized help feel free to post.
I might also put some programming tasks here for practice.
Advertising

TJMIG
Posts: 1
Joined: Fri Mar 27, 2015 4:21 pm

Re: 10 Days of Basic Programming: Discussion and Help

Post by TJMIG » Sun Mar 29, 2015 2:43 pm

Do you know any well constructed resources that cover piping, fuzzing, firmware dumping, or rop programming? Do gaming homebrew coders or reversers use tools like IDA Pro? If so, how do they go about setting it up to decompile the necessary files to achieve code execution. Are there ways to tell if a file that has been found during a firmware dump have root access(I assume those are the necessary files needed to be reversed in order to achieve arbitrary code execution)? Sorry for so many questions, I have been using gaming homebrew since ps1, I just really want to contribute to the scene.
Advertising

User avatar
Acid_Snake
Retired Mod
Posts: 3099
Joined: Tue May 01, 2012 11:32 am
Location: Behind you!

Re: 10 Days of Basic Programming: Discussion and Help

Post by Acid_Snake » Fri Apr 03, 2015 10:39 pm

Game development and game hacking (or hacking in general) are two completely different worlds where completely different knowledge and tools are used. The tools to use and the documentation is scattered all around the internet, I can answer and help with specific questions of problems, but nothing as generic as game development or hacking, there's just too much to talk about.

hrosales
Posts: 3
Joined: Thu Dec 12, 2013 5:44 pm

Re: 10 Days of Basic Programming: Discussion and Help

Post by hrosales » Fri Apr 10, 2015 8:36 pm

I would like to ask, I haven't read any of the other days of programming, and I wonder, I am a financial analyst...far away about programming, but I would like to learn some basics about programming, could I star here?...I mean, I have zero knowledge, of this mean that you need basic knowledge, which is logical.

I really appreciate your hard work on this, since I am one of those who just enjoy the work and effort of the developers.

User avatar
Acid_Snake
Retired Mod
Posts: 3099
Joined: Tue May 01, 2012 11:32 am
Location: Behind you!

Re: 10 Days of Basic Programming: Discussion and Help

Post by Acid_Snake » Sun Apr 12, 2015 2:43 pm

Well now would be a good moment to read my 10 Days of Basic Programming tutorial. It covers all the basic stuff you need to know about programming.

User avatar
SpecBit
Posts: 1
Joined: Tue May 19, 2015 9:34 pm

Exercise 1

Post by SpecBit » Wed May 20, 2015 1:46 am

Hi Acid_Snake

It's been a while since I was forced to leave the programming world. Due to a physical condition it has been almost a year since I stopped studying programming. Now here's the thing: I came across your article by coincidence and as I was reading the begining I found it interestting as a review. So i did what I was set do do for almost a year, getting back to programming. It is not the first time in my short adventure in the programming world that I have to stop for a long period of time. First time it happened to me, I went to a job interview to do a Java test, eventough I wasn't dealing with it for an year or so. The result was a complete disaster. It only means that I know how much trouble can come by leaving programming for a few months.
I understand that you're in college, well so am I (at least I hope to get back next September). I have a few questions that I would like to ask you but I would rather to do it in private at this point (if you don't mind that is).
Regarding your challenge, I gave it a go and began the first exercise. Funny because something unexpectd, for me at least, happend. I had an error, wich is fixed, but before I post the correct solution, the one that compliles and runs that is, I'm going to share the bad code:

Code: Select all

#include <stdio.h>
#include <stdlib.h>

int main()
{
    int arr[10];
    int i;

//    for ( i = 0; i < 10; i++ )
//    {
//        if ( i % 2 == 0 )
//        {
//            arr[i] = 0;
//        }
//
//        else arr[i] = 1;
//    }

    for ( i = 0; i < 10; i++ )
    {
         i % 2 == 0 ? arr[i] = 0 : arr[i] = 1;
    }

    /* Just to check the result */
    for ( i = 0; i < 10; i++ )
    {
        printf ( "%d ", arr[i] );
    }

    return 0;
}
Anyway Acid_Snake, the thing with the code happenns in the ternary operator line. Somehow the parsing is not done properly. Went to stackoverflow, got some explanations but the major flaw in that line of code I can't understand why it happens. Like i told you, I've an iproved version of code that I'm going to post just as soon as you reply to this one.
About the article itself, what caught my attention was that I read somewhere that this was a tutorial for beguinners, who wanted to become game programmers or something like that. Surprise, it got me back on my desk typing code. For that I thank you.
If there's a way to send PM, please alow me to do so. My only interest is programming and maybe you can point me in the right direction of what I have been searching for years. And for that I will thank you.

User avatar
GBOT
Developer
Posts: 320
Joined: Wed Apr 25, 2012 8:00 pm
Contact:

Re: 10 Days of Basic Programming: Discussion and Help

Post by GBOT » Wed May 20, 2015 2:44 am

This is the correct way of using the ternary operator:

Code: Select all

arr[i] = (i % 2 == 0)? 0: 1;
You could avoid it and go easier on the cpu though:

Code: Select all

arr[i] = i & 1;
Github
Twitter

Can't give enough crepes

User avatar
Zafotheninja
Posts: 101
Joined: Wed Apr 18, 2012 10:40 pm
Location: Beyond the furthest ring.

Re: 10 Days of Basic Programming: Discussion and Help

Post by Zafotheninja » Wed Jul 15, 2015 2:33 am

Acid_Snake wrote:Well now would be a good moment to read my 10 Days of Basic Programming tutorial. It covers all the basic stuff you need to know about programming.
I have been reading through the "10 days of basic programing" and found it a quite interesting read. I got up to "day 7" but then could not find the next "day", does it exist or was the series discontinued due to work? I am looking forward to the completion of this series and in reading the Intermediate series as well. (Why have these not been posted in security++, these would be great material for that section.)

Thanks for your time.
If I come off as an ***, I'm sorry, I don't mean to 87.6% of the time.

User avatar
Acid_Snake
Retired Mod
Posts: 3099
Joined: Tue May 01, 2012 11:32 am
Location: Behind you!

Re: 10 Days of Basic Programming: Discussion and Help

Post by Acid_Snake » Wed Sep 16, 2015 6:11 am

I gotta finish the series, been busy lately.

User avatar
PKGTR
Posts: 2
Joined: Sat Apr 14, 2012 11:26 pm

Re: 10 Days of Basic Programming: Discussion and Help

Post by PKGTR » Sun Sep 20, 2015 1:41 am

Acid_Snake wrote:I gotta finish the series, been busy lately.
Please do.

I learned more in one weekend with 10DoBP than I did over the course of a year in traditional university CS classes.

Just thought I would chirp in and express my thanks; pretty sure I'm not the only one who feels this way.

Post Reply

Return to “Programming and Security”