Sync LockAfter JDk1.5, Java provides another thread synchronization mechanism: it implements thread synchronization by explicitly defining a synchronization lock object, in which case the synchronization lock should use the lock object to act.It is
Array Sort Summary Packagemain.java.cellar.test;/*** Created by Cui on 9/27/14.*/ Public classArraysorts {/** * @paramargs*/ Public Static voidMain (string[] args) {int[] Number = {95, 45, 15, 44, 66, 88, 77 }; //bubblesort (number);
Code Hosting Address: Summary of learning contents of http://git.oschina.net/null_289/Java2016 TextbookI. Log APIThe starting point for using the log is the logger class, where the logger instance is created with many features to be processed, and
The shift operators in Java have three ">", ">>>", and No "The "The ">>" operator shifts the bits to the right and fills the high position with the sign bit;The >>> operator shifts the bits to the right, but fills the high with the zeros.Note: The
Java constant pool is a long-lasting topic, but also the interviewer's favorite, the title of a variety of, side dishes have already heard of the constant pool, this time a good summary.TheoryIt's a little bit awkward. JVM Virtual Memory
The collection in Java is a very important point, to consolidate the knowledge of the study here, the knowledge of the rationaleAccording to the horse soldier's video, the summary is also very good, the collection is a "1136"1 graphs, 1 classes
Recent projects in the performance of the Alarm module optimization, many places using the thread pool technology, summarized as follows.Package Com.coshaho.threadpool;import Java.util.concurrent.blockingqueue;import java.util.concurrent.Executors;
This week the information security class did the DES encryption algorithm experiment, needs to the bit operation. Here's a summary:1 byte = 8 bitThere is no bit data type in Java, so you can have a numeric value (1,0) for each bit in the byte[]
Java learning to receive input characters from the consoleTools: NetBeansThe system class has an implementation of the in input stream in addition to the out and err two output streams.To create a class casually, I am using the Helloword class to
20145317 Peng Yao "Java Program Design" 8th Week study summary textbook Study content summary 14th Chapter 1.NIO DefinitionThe input and output of InputStream, OutputStream, is basically in bytes for low-level processing, although the need to
First, the Java design pattern in a total of 23. Of these 23 can be broadly divided into 3 categories, the specific sub-method is as follows:1, the creation mode: involves the design pattern altogether 5 kinds, respectively is:Factory method mode,
A run-time constant pool is a part of a method area that holds information about a class, such as its name, access modifiers, Chang, field descriptions, method descriptions, and so on.String.intern () is a native method that returns a String object
1. Two fork Find tree Binary search trees (binary search tree)/ordered binary tree (ordered binary tree)/Sort binary trees (sorted binary)1). If the left subtree of any node is not empty, then the value of all nodes on the left subtree is less than
When doing the project, the page gets the problem. Looking for a long time always thought it was me. The field or database field is causing the problem.Finally found that it is struts2 JSP I wrote a wrong parameter, has led to error. It was better
1. Basic terminologyDegree (degree): The number of subtrees of a node is called the degree of the node, and the maximum node degree in the tree is called the degree of the tree.Layer (Level): Count from root node, 1 for RootHeight/Depth (depth):
1. Processes and ThreadsProcess: run a speed in which the program allocates the running space in memoryThreads: Run in a process and can switch between multiple threads.The relationship between the problem process and the thread?processes include
Synchronized for java concurrency
In Java, each object has a lock mark (monitor), also known as a monitor. When multiple threads access an object at the same time, the thread can only access the Lock of this object.
In Java, you can use the
About static code block, common code block, synchronous code block, constructor and constructor
ConstructorUsed to initialize an object. It is a type of function that initializes the corresponding object.Features:1: The name of the function is the
21. Merge Two Sorted Lists, mergesorted
Merge two sorted linked lists and return it as a new list. The new list shoshould be made by splicing together the nodes of the first two lists.
The Code is as follows:
1 /** 2 * Definition for singly-linked
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