Circular list (one way + two way)

1, One way circular list 1. One way circular list details In fact, a unidirectional circular list is a pointer to the head node of the end node. Generally, the end node of the list points to null. When adding a node, the tail situation is the same as the normal situation, and no special processing i ...

Posted by ghqwerty on Sun, 23 Feb 2020 07:46:35 +0100

The programming problem of Niuke network: the solution of jumping stone board

Title Description Xiaoyi came to a stone road, each stone from 1 next to the number: 1, 2, 3 This flagstone road can only advance according to special rules: for the flagstone whose number is k, Xiaoyi can only jump forward one divisor step of K (excluding 1 and K) at a time, that is, jump to the posi ...

Posted by alcapone on Sat, 22 Feb 2020 09:01:53 +0100

Thinking In Java - type information reading notes and excerpts

Runtime type information allows you to discover and use type information while the program is running. In Java, there are two main ways for us to recognize the information of objects and classes at run time: the first is "traditional" RTTI, which assumes that we have known all types at compile ...

Posted by p.utsav on Mon, 17 Feb 2020 09:50:32 +0100

Presto cluster deployment (upgrade)

Let's talk about the last step of preparing to upgrade presto, because the pre deployed Presto machine itself deployed a CDH cluster (customer's home), and the machine was Centos6.x. according to the JDK on the Cloudrea official website, it can't move. Later, it was found that his JDK environment variab ...

Posted by B of W on Tue, 11 Feb 2020 11:48:16 +0100

Summary of the mistakes in Niuke's real questions JAVA

Which of the following methods is used to define the thread's execution body (): run() ==The memory address is judged. integer can call cache directly when it gives int value between - 127 and 128, so if the memory address is the same, an object will be new if it exceeds this range, and false will be re ...

Posted by prosolutions on Fri, 07 Feb 2020 14:11:13 +0100

Java agent learning summary

Preface Recently, because of the company's needs, we need to understand the java probe, find information on the Internet, and find a lot of data, but there are too few examples. Some of them paste the company code directly, which is too complex, and some of them are particularly simple, which is not what I want. I want an example like this: The ...

Posted by mohamdally on Sat, 01 Feb 2020 11:42:40 +0100

Control concurrent processes

1 what is controlling concurrent processes? The tool class that controls concurrent processes is used to help our programmers make it easier for threads to cooperate Let threads cooperate with each other to meet business logic For example, let thread A wait for thread B to finish executing befor ...

Posted by JackOfBlades on Thu, 30 Jan 2020 05:13:25 +0100

java obtains server cpu, memory and other data through sigar

First, introduce the sigar package implementation 'org.fusesource:sigar:1.6.4' Secondly, Under windows environment, put the three files of sign-amd64-winnt.dll, sign-x86-winnt.dll and sign-x86-winnt.lib in the bin directory of jdk Or configuration under Windows: select sign-amd64-winnt.dll or ...

Posted by sfarid on Mon, 20 Jan 2020 17:18:10 +0100

JNI introduction series I, the first JNI program

First, write a simple class, which contains a native method public class JNI{ static{ // Load the dynamic link library, which we will create below System.loadLibrary("hello_jni"); } public native void hello(); public static void main(String[] args){ JNI jni = new JNI(); jni.hello(); } } ...

Posted by GreenMarch on Sun, 19 Jan 2020 11:52:11 +0100

Prove java object header biased lock, lightweight lock, heavyweight lock and their performance comparison

  1. Biased lock: the biased lock mode is used to bias the lock to a given lock thread. When this mode is set to the lower three bits, the lock may be biased toward a particular thread or "anonymous", indicating that it may be biased. When a lock is biased toward a given thread, locking an ...

Posted by nephish on Thu, 16 Jan 2020 07:51:45 +0100