DXC Technology interview question

Write prime number program and few questions based on java