zoukankan      html  css  js  c++  java
  • Java线程池

    import java.util.concurrent.ExecutorService;
    import java.util.concurrent.Executors;
    import java.util.concurrent.*;
    
    /*
    ExecutorService instance = Executors.newCachedThreadPool();  		| instance.execute(new Runnable())
    ExecutorService instance = Executors.newFixedThreadPool(3);   		| instance.execute(new Runnable())
    ExecutorService instance = Executors.newSingleThreadExecutor();  	| instance.execute(new Runnable())
    
    ScheduledExecutorService scheduledThreadPool = Executors.newScheduledThreadPool(5); 
    scheduledThreadPool.schedule(new Runnable(),delay_time, TimeUnit.SECONDS);
    scheduledThreadPool.scheduleAtFixedRate(new Runnable(),delay_time, shedule_time, TimeUnit.SECONDS);
    */
    
    
  • 相关阅读:
    2015多校.Zero Escape (dp减枝 && 滚动数组)
    UVa-11809
    UVa-1588 Kickdown
    UVa-1587
    UVa-10340
    UVa-202
    UVa-1368
    UVa-232 Crossword Answers
    UVa-227
    UVa-455 Periodic Strings
  • 原文地址:https://www.cnblogs.com/blbl9527/p/8177587.html
Copyright © 2011-2022 走看看