hello
tnx everyone this forum really helps me sometimes!
can someone please tell me how i can convert a double number to nearest integer number?

int x;
double d=99.8;
x=Math.round(d);
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.