Convert Figma logo to code with AI

crossoverJie logoJCSprout

👨‍🎓 Java Core Sprout : basic, concurrent, algorithm

27,068
7,091
27,068
45

Top Related Projects

😮 Core Interview Questions & Answers For Experienced Java(Backend) Developers | 互联网 Java 工程师进阶知识完全扫盲:涵盖高并发、分布式、高可用、微服务、海量数据处理等领域知识

174,630

:books: 技术面试必备基础知识、Leetcode、计算机操作系统、计算机网络、系统设计

145,827

「Java学习+面试指南」一份涵盖大部分 Java 程序员所需要掌握的核心知识。准备 Java 面试,首选 JavaGuide!

【Java面试+Java学习指南】 一份涵盖大部分Java程序员所需要掌握的核心知识。

To Be Top Javaer - Java工程师成神之路

Everything you need to know to get the job.

Quick Overview

JCSprout is a comprehensive Java learning resource repository on GitHub. It covers a wide range of Java-related topics, including core Java concepts, concurrent programming, distributed systems, and algorithm implementations. The project aims to provide in-depth knowledge and practical examples for Java developers of all levels.

Pros

  • Extensive coverage of Java topics, from basics to advanced concepts
  • Well-organized content with clear explanations and code examples
  • Regularly updated with new information and improvements
  • Includes practical examples and real-world scenarios

Cons

  • Primarily written in Chinese, which may limit accessibility for non-Chinese speakers
  • Some topics may lack depth compared to dedicated resources or textbooks
  • Navigation can be overwhelming due to the large amount of content
  • May require prior Java knowledge to fully benefit from some advanced topics

Code Examples

Since JCSprout is primarily a learning resource repository rather than a code library, it doesn't have a specific API or set of functions to demonstrate. However, it does contain numerous code examples within its documentation. Here are a few examples from different sections:

  1. Thread creation example:
public class ThreadDemo {
    public static void main(String[] args) {
        Thread thread = new Thread(() -> {
            System.out.println("Hello from a new thread!");
        });
        thread.start();
    }
}
  1. Singleton pattern implementation:
public class Singleton {
    private static volatile Singleton instance;

    private Singleton() {}

    public static Singleton getInstance() {
        if (instance == null) {
            synchronized (Singleton.class) {
                if (instance == null) {
                    instance = new Singleton();
                }
            }
        }
        return instance;
    }
}
  1. Binary search algorithm:
public static int binarySearch(int[] arr, int target) {
    int left = 0, right = arr.length - 1;
    while (left <= right) {
        int mid = left + (right - left) / 2;
        if (arr[mid] == target) return mid;
        if (arr[mid] < target) left = mid + 1;
        else right = mid - 1;
    }
    return -1;
}

Getting Started

To get started with JCSprout:

  1. Visit the GitHub repository: https://github.com/crossoverJie/JCSprout
  2. Clone the repository or download the ZIP file
  3. Navigate through the README.md file to find topics of interest
  4. Explore the relevant markdown files in the repository for detailed explanations and code examples

Note that most content is in Chinese, so non-Chinese speakers may need to use translation tools to fully benefit from the resource.

Competitor Comparisons

😮 Core Interview Questions & Answers For Experienced Java(Backend) Developers | 互联网 Java 工程师进阶知识完全扫盲:涵盖高并发、分布式、高可用、微服务、海量数据处理等领域知识

Pros of advanced-java

  • More comprehensive coverage of advanced Java topics
  • Better organized structure with clear categorization
  • Regularly updated with new content and examples

Cons of advanced-java

  • May be overwhelming for beginners due to its extensive content
  • Less focus on basic Java concepts compared to JCSprout

Code Comparison

advanced-java example (Distributed Lock):

public class RedisLock {
    public boolean lock(String key, String value, long expireTime) {
        return jedis.setnx(key, value) == 1 && jedis.expire(key, expireTime) == 1;
    }
}

JCSprout example (Thread Pool):

ThreadPoolExecutor executor = new ThreadPoolExecutor(
    corePoolSize,
    maxPoolSize,
    keepAliveTime,
    TimeUnit.SECONDS,
    new LinkedBlockingQueue<>(queueSize)
);

Both repositories provide valuable resources for Java developers, with advanced-java offering a more extensive and structured approach to advanced topics. JCSprout, while less comprehensive, may be more suitable for those looking for a concise overview of Java concepts. The code examples demonstrate the different focus areas of each repository, with advanced-java emphasizing distributed systems and JCSprout covering core Java features.

174,630

:books: 技术面试必备基础知识、Leetcode、计算机操作系统、计算机网络、系统设计

Pros of CS-Notes

  • More comprehensive coverage of computer science topics, including operating systems, networks, and databases
  • Better organized structure with clear categorization of subjects
  • Includes more visual aids like diagrams and charts to explain complex concepts

Cons of CS-Notes

  • Less focus on practical Java programming compared to JCSprout
  • May be overwhelming for beginners due to the breadth of topics covered
  • Updates less frequently than JCSprout

Code Comparison

CS-Notes example (Java):

public class Singleton {
    private static Singleton instance;
    private Singleton() {}
    public static Singleton getInstance() {
        if (instance == null) {
            instance = new Singleton();
        }
        return instance;
    }
}

JCSprout example (Java):

public class Singleton {
    private static volatile Singleton instance;
    private Singleton() {}
    public static Singleton getInstance() {
        if (instance == null) {
            synchronized (Singleton.class) {
                if (instance == null) {
                    instance = new Singleton();
                }
            }
        }
        return instance;
    }
}

The code comparison shows that JCSprout provides a more thread-safe implementation of the Singleton pattern using double-checked locking, while CS-Notes offers a simpler but potentially less robust version.

145,827

「Java学习+面试指南」一份涵盖大部分 Java 程序员所需要掌握的核心知识。准备 Java 面试,首选 JavaGuide!

Pros of JavaGuide

  • More comprehensive coverage of Java topics, including frameworks and tools
  • Better organized structure with clear categories and subcategories
  • More frequent updates and contributions from the community

Cons of JavaGuide

  • Can be overwhelming for beginners due to the vast amount of information
  • Some topics may lack depth compared to JCSprout's focused approach

Code Comparison

JCSprout example (Thread communication):

public class WaitAndNotify {
    private static Object lock = new Object();
    
    public static void main(String[] args) {
        new Thread(new ThreadA()).start();
        new Thread(new ThreadB()).start();
    }
}

JavaGuide example (Thread creation):

public class MyThread extends Thread {
    @Override
    public void run() {
        System.out.println("MyThread running");
    }
}

MyThread t = new MyThread();
t.start();

Both repositories provide valuable resources for Java developers, but they cater to different needs. JCSprout focuses on core Java concepts and in-depth explanations, while JavaGuide offers a broader overview of Java ecosystem with more topics covered. The choice between the two depends on the developer's specific learning goals and experience level.

【Java面试+Java学习指南】 一份涵盖大部分Java程序员所需要掌握的核心知识。

Pros of JavaFamily

  • More comprehensive coverage of Java ecosystem topics
  • Regular updates and active community engagement
  • Includes practical interview preparation materials

Cons of JavaFamily

  • Less structured organization compared to JCSprout
  • May be overwhelming for beginners due to extensive content
  • Some topics lack in-depth explanations

Code Comparison

JCSprout example (Thread creation):

public class ThreadExample extends Thread {
    @Override
    public void run() {
        System.out.println("Thread is running");
    }
}

JavaFamily example (Lambda expression):

List<Integer> numbers = Arrays.asList(1, 2, 3, 4, 5);
numbers.forEach(n -> System.out.println(n));

Both repositories provide code snippets to illustrate concepts, but JavaFamily tends to include more modern Java features and practical examples.

Summary

JCSprout offers a well-structured approach to Java core knowledge, while JavaFamily provides a broader range of topics and more up-to-date content. JCSprout may be more suitable for beginners, whereas JavaFamily caters to a wider audience, including those preparing for interviews. Both repositories have their strengths, and developers may benefit from using them in combination to gain a comprehensive understanding of Java development.

To Be Top Javaer - Java工程师成神之路

Pros of toBeTopJavaer

  • More comprehensive coverage of Java topics, including advanced concepts and industry practices
  • Better organized structure with clear categorization of subjects
  • Includes practical examples and real-world scenarios for better understanding

Cons of toBeTopJavaer

  • Less focus on in-depth explanations of core Java concepts
  • Fewer code snippets and practical implementations compared to JCSprout
  • May be overwhelming for beginners due to the breadth of topics covered

Code Comparison

JCSprout example (Thread creation):

public class MyThread extends Thread {
    @Override
    public void run() {
        System.out.println("MyThread running");
    }
}

toBeTopJavaer example (Lambda expression):

List<String> names = Arrays.asList("Alice", "Bob", "Charlie");
names.forEach(name -> System.out.println(name));

Both repositories provide valuable resources for Java developers, but they cater to slightly different audiences. JCSprout focuses more on core Java concepts with detailed explanations and code examples, while toBeTopJavaer offers a broader range of topics and industry-relevant information. The choice between the two depends on the learner's goals and experience level.

Everything you need to know to get the job.

Pros of interviews

  • Broader coverage of computer science topics, including algorithms, data structures, and system design
  • More comprehensive preparation for technical interviews across various companies
  • Includes solutions in multiple programming languages

Cons of interviews

  • Less focus on Java-specific concepts and best practices
  • May not cover in-depth Java ecosystem topics like JVM internals or Spring framework
  • Lacks detailed explanations of core Java concepts

Code comparison

interviews:

def reverse(head):
    prev = None
    while head:
        temp = head.next
        head.next = prev
        prev = head
        head = temp
    return prev

JCSprout:

public ListNode reverseList(ListNode head) {
    ListNode pre = null;
    ListNode cur = head;
    while(cur != null) {
        ListNode nextTemp = cur.next;
        cur.next = pre;
        pre = cur;
        cur = nextTemp;
    }
    return pre;
}

Both repositories provide similar implementations for reversing a linked list, but JCSprout focuses on Java-specific code, while interviews offers solutions in multiple languages.

Convert Figma logo designs to code with AI

Visual Copilot

Introducing Visual Copilot: A new AI model to turn Figma designs to high quality code using your components.

Try Visual Copilot

README


Build Status QQ群


Java Core Sprout:处于萌芽阶段的 Java 核心知识库。

访问这里获取更好的阅读体验:https://crossoverjie.top/JCSprout/


202405171520366.png

最近开通了知识星球,感谢大家对 JCSprout 的支持,为大家提供 100 份 10 元优惠券,也就是 69-10=59 元,具体福利大家可以扫码参考再决定是否加入。

PS: 后续会继续维护该项目,同时加入现在热门的 Golang/kubernetes/OpenTelemetry 等知识点,感兴趣的可以加入星球当面催更(当然内容也会更新到这个项目里)。

📊⚔️🖥🚏🏖🌁📮🔍🚀🌈💡
集合多线程JVM分布式框架架构设计数据库算法Netty附加技能联系作者

常用集合

Java 多线程

JVM

分布式相关

常用框架\第三方组件

架构设计

DB 相关

数据结构与算法

Netty 相关

附加技能

联系作者

crossoverJie#gmail.com

index.jpg