You are given a binary file containing unsorted unsigned 32-bit integers.
The file contains up to 2^20 random, unique integers, encoded in big-endian format.
Each integer will be in the range [0, 2^25).
Write a program that, given an integer in range [0, 2^25), will return the closest integer from the input file.
If there is a tie for the closest, return the lower one.
Your program should take one command-line argument:
./query <path_to_input_file>
Your program should read test cases from standard input and write results to standard output, one per line.
Hi, Dear Employer!
I am really interested in your project.
I have enough experience in Python, C/C++, C#, java programming.
I am 100% sure I can satisfy your requirements perfectly.
User-Friendly Interface And Clear Algorithm Will Encourage Your Project.
I want a long-term relationship with you.
Thank you and best regards!
hello,how are you. i read your bid carefully.
i am c/c++ expert and have full experience for 10 years.
c++ language is my top skill.
i can provide most quality and high speed.
if you want to success, please contact me.
Then, I will give you good result to the proposals.
hire me.
Hello there,
Myself Prakhar, i am working in C, python and C++ for last 3 years.
I have read your description thoroughly and i am confident that i can do this easily.
Let's discuss further in personal chat.
Regards Prakhar.