Using a table with the 256 bytes as strings, said table is used as a reference in the 2 functions of this code. Functions who make the conversion such as the title establishes, and in the inverse way too.
The main adventage is that you don't need any knowledge about managing bytes with c++..
The real advantage to using a look-up table is that the code will run much faster than doing a bunch of calculations. However, doing a linear scan through the table to find its inverse function, as you have done in Test2(), will run very slowly. You could use another look-up table to convert the hexadecimal characters back to decimal numbers.
Note: Calling the strlen() function inside the test condition of the for loop means it will be called for every iteration of the loop. This is very inefficient since the strlen() function must loop through the character array every time to determine the length. If you are going to use the strlen() function, assign the result to a variable and use that variable in the loop's test condition.
huong dan ca cuoc tren mang
huong dan ca cuoc online
huong dan ca do bong da
huong dan ca cuoc bong da
huong dan ca do tren mang
huong dan ca cuoc tren mang
huong dan ca cuoc bong da
yeahh well about that of the strlen, i knew that it would be made every loop, but this is actually the second version of this program.. see the previous version: http://foro.elhacker.net/programacio...t383814.0.html
perhaps I didn't care about taht i'm not sure
great idea with the second function!, the first function uses the table to "lookup", but the second didn't manage to make that. The idea was anyways to make a program to manage this conversion, for a person that doesn't know about bytes managing, that's why my code hasn't applied the normal logic to handle byte to decimal convertion, and the inverse operation.
* The Best Reasons to Target Windows 8
Learn some of the best reasons why you should seriously consider bringing your Android mobile development expertise to bear on the Windows 8 platform.