Home java System.ArrayCopy implementation. Java

System.ArrayCopy implementation. Java

Author

Date

Category

Hello. There is a question, somebody knows how to implement System.ArrayCopy in Java.
Everyone knows that the built-in system.arraycopy (a, 0, b, 0, 2) parameters that there is an array from which we will copy, starting with which element, the array to which we will copy, starting From which element and how many elements.
Obviously, work with n & gt; 100 elements, speed exceeds cycle copying. So what is the secret? It turns out that the method copies these blocks?


Answer 1, Authority 100%

if you run OpenJDK source sources , it is easy to make sure that System.ArrayCopy is just Memmove wrapped by pelleton checks.

Programmers, Start Your Engines!

Why spend time searching for the correct question and then entering your answer when you can find it in a second? That's what CompuTicket is all about! Here you'll find thousands of questions and answers from hundreds of computer languages.

Recent questions