munir hussain

Greenhorn
+ Follow
since Mar 05, 2009
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by munir hussain

what is metadata or annotations. and for which purpose it is used?
15 years ago
hello dear all

i am looking for "The SCJP5 Study Guide by Kathy Sierra and Bert Bates" with the practice exams included with the book.

can please anyone help.. as i need it urgently

regards to all helpers
how to convert a hex or binary number to decimal and vice versa using a any java mehtod, can any one help.
and one more thing that can any one explain how computer store and retrieve - sign . i am so much confusd with left and right shifts

i have mentioned 2 codes here.
1). our input variable "int num = 0xFFFFFFE". how after all operations the result
comes in decimal
.
2). we have a String array of hex numbers. how the resultant values are searched in the array.and why weare doing
"[(b >> 4) & 0x0f]" and [b & 0x0f].

any solid reasons

examle1

// Left shifting as a quick way to multiply by 2.
class MultByTwo {
public static void main(String args[]) {
int i;
int num = 0xFFFFFFE;
for(i=0; i<4; i++) {
num = num << 1;
System.out.println(num);
}
}
}

The program generates the following output:
536870908
1073741816
2147483632
-3

example 3

// Masking sign extension.
class HexByte {
static public void main(String args[]) {
char hex[] = {
'0', '1', '2', '3', '4', '5', '6', '7',
'8', '9', 'a', 'b', 'c', 'd', 'e', 'f'
};
byte b = (byte) 0xf1;
System.out.println("b = 0x" + hex[(b >> 4) & 0x0f] + hex[b & 0x0f]);
}
}
Here is the output of this program:
b = 0xf1
15 years ago



how to convert a hex or binary number to decimal and vice versa using a any java mehtod, can any one help.
and one more thing that can any one explain how computer store and retrieve - sign . i am so much confusd with left and right shifts

your help will be appreciated.
regards
munir
15 years ago
Hello

need your help and suggestion . i am planning to take scjp 5. i am new beginner in java. till now i have completed, first 14 chapters of java complete reference j2se - 5 . which covers

1 The Genesis of Java
2 An Overview of Java
3 Data Types, Variables, and Arrays
4 Operators
5 Control Statements
6 Introducing Classes
7 A Closer Look at Methods and Classes
8 Inheritance
9 Packages and Interfaces
10 Exception Handling
11 Multithreaded Programming
12 I/O, Applets, and Other Topics
13 String Handling
14 Exploring java.lang

also i write the examples which are in this book. now i am starting with "SCJP Sun Certified Programmer for Java 5 Study Guide (Exam 310-055) by Kathy SierraandBert Bates" now if i finish this book and do some free available mocks on java ranch or from other site , is it possible that i can pass the exam. i am on vacactions from my job and have almost 24 days and my exam date is 30 march. kindly suggest me any study plan and tell me can i do it in the given period of time and pliz also give me links of some mock tests for scjp 5.
i will be very thankfull to you . as for the time being im so tensed that i can make it or not

regards

Muneer hussain