Tag:Multiple

  • Java 9 Series Part 7: java.util.optional optimization and enhancement

    Time:2021-9-3

    I plan to write a series of articles about Java 9 in the next period of time. Although Java 9 is not the core Java version like Java 8 or Java 11, there are still many features worth paying attention to. I hope you can pay attention to me. I will write java 9 into […]

  • Implementation of C + + code of tea encryption algorithm

    Time:2021-7-9

    The encryption algorithm of tea is realized by C + +, and finally compiled into so file, which is provided to the client in JNI mode. The following three problems need to be solved Implementation of tea algorithm, which has open source code can be achieved; Solve the padding problem; The key should be confused […]

  • Less — common layout

    Time:2021-7-6

    flex .flex-container { display: flex; &.flex-align-center { align-items: center; } } .flex-item { flex: 1; } // .flex-shrink { // position: relative; // flex-shrink: 1; // -ms-flex-negative: 1; // -webkit-flex-shrink: 1; // -ms-flex: 0 1 auto; // flex: 0 1 auto; // } @col: 6; .mixin-loop (@i) when (@i > 0) { &[email protected]{i} { flex: […]

  • [front end algorithm] zero after factorization, twice traversal

    Time:2021-6-6

    Given an integer n, return n! The number of zeros in the result mantissa. Example 1: Input: 3 Output: 0 Explanation: 3= 6, there is no zero in the mantissa. Example 2: Input: 5 Output: 1 Explanation: 5= 120, one zero in the mantissa Note: the time complexity of your algorithm should be o (log […]

  • Leetcode 204

    Time:2021-4-1

    Title Requirements thinking Create an array mylist, the length of which is n, and initialize all elements of the array to true Create another array res to hold prime numbers The 0 subscript position of the array is assigned to FALS, indicating that 1 is not a prime number Traverse the array subscript 1 ~ […]

  • [title] card grouping – lotcode

    Time:2021-3-2

    Title: card grouping Given a deck of cards, an integer is written on each card. At this point, you need to select a number x, so that we can divide the whole deck into one or more groups according to the following rules: Each group has X cards.All cards in the group have the same […]

  • Solution to multiple primary key defined error in MySQL

    Time:2021-2-7

    There are two ways to create a primary key: Create table name( Field name type, Field name type, …… primary key(name) ); Or is it Create table name( Field name type primary key, Field name type, …… ); But note that if you want to create a composite primary key, you can’t use the second […]

  • Chapter 5: divisibility and the greatest common factor (1)

    Time:2020-12-7

    Suppose m and N are integers,m\neq 0。 If n is a multiple of M, there exists an integer k such thatn= mk。 If M is divisible by N, we write it asm|n; ifmDo not dividen, we remember asm\nmid n。 For example, because6=3·2, so3|6。6The factor of is1,2,3。 Because there is no5A multiple of is equal to7, […]

  • Chapter 6: linear equations and the greatest common factor (2)

    Time:2020-12-3

    Now, we know the equation ax+by=gcd(a,b) There is always an integer solutionxAndyHow many solutions are there and how to express them?We are mutually exclusiveaAndbLet gogcd(a,b)=1, assuming(x_1,y_1)It’s an equationax+by=1A solution of. adoptx_1subtractbSum of multiples ofy_1addaOther solutions can be obtained. In other words, for any integerkWe get a new solution(x_1+kb,y_1-ka)By calculating a(x_1+kb)+b(y_1-ka)=ax_1+akb+by_1-bka=ax_1+by_1=1 Still observinggcd(a,b)=1It can be proved […]

  • Retry mechanism

    Time:2020-8-15

    There are two mechanisms for retrying: guava and spring. Guava retryer tool POM reference <dependency> <groupId>com.github.rholder</groupId> <artifactId>guava-retrying</artifactId> <version>2.0.0</version> </dependency> test method Retryer<Boolean> retryer = RetryerBuilder.<Boolean>newBuilder() .retryIfExceptionOfType(Exception.class) //If you return false, you also need to try again .retryIfResult(Predicates.equalTo(false)) //Reorientation strategy .withWaitStrategy(WaitStrategies.fixedWait(1, TimeUnit.SECONDS)) //Number of attempts .withStopStrategy(StopStrategies.stopAfterAttempt(3)) .build(); try { //Executes the specified method. retryer.call(() -> { […]

  • Vue + gaude map to realize track playback and play progress bar / multiple / time

    Time:2020-8-13

    Demand:1: Track playback: play, pause, resume2: Progress bar, track playback, progress bar should also play, track stop playing, progress bar should be suspended.3: Multiple: not playing selection multiple, playing selection multiple, pause selection multiple.4: Play time In the Gaode API example, only the simplest play, pause and continue to play is required.Therefore, it is necessary […]

  • (44) C × WinForm custom control – water wave – hzhcontrols

    Time:2020-5-25

    Official website http://www.hzhcontrols.com premise It’s been 7 or 8 years since I started, I always want to make a set of beautiful custom controls, so I have this series of articles. GitHub:https://github.com/kwwwvagaa/NetWinformControl Code cloud: https://gitee.com/kwwwvagaa/net_ winform_ custom_ control.git If you think it’s OK, please click star to support it Welcome to discuss: Penguins 568015492 Please […]