Input stream output stream access

Source: Internet
Author: User

Input and output are relative to JVM.

Reading data from the outside to the JVM memory is an input relative to the JVM.
Writing data from JVM memory to files or other places is output relative to JVM

 

Random Access

In the data structure, random access means the ability to access N values in a pile of numbers at a constant time, in addition to arrays (and related structures, such as dynamic arrays, very few data structures can make similar programs. In addition, random access is indispensable for many algorithms, such as fast sorting and binary search. Other data structures, such as linked lists, sacrifice random access in exchange for efficient insertion, deletion, or sorting. Sequential access is the opposite of random access. For example, a linked list has a "head Pointer" variable that stores an address pointing to the first node in the linked list, the first node points to the second node ...... Until the last node. This node no longer points to other nodes. It is called "Table tail". Its address section stores a "null" (indicating "Empty address"), and the linked list ends here. Each node in the linked list contains two parts: the actual data required by the user and the address of the next node. We can see that the nodes in the linked list can not be stored continuously in the memory. To locate a node C, you must first find its previous Node B, and then find C according to the next node address provided by Node B. The linked list has a "header Pointer". Therefore, the "header Pointer" can be used to locate any node in the linked list in sequence. If "header Pointer" is not provided, the entire linked list cannot be accessed. Like an iron chain, a linked list cannot be broken.

Input stream output stream access

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.