- 博客(3)
- 收藏
- 关注
原创 关于纸牌的代码
纸牌public class PlayingCards { private static final String[] CARD_VALUE = new String[]{"3", "4", "5", "6", "7", "8", "9", "10", "J", "Q", "K", "A", "2"}; private static final String[] CARD_COLOR = new String[]{"红桃", "黑桃", "方片", "梅花"}; public
2020-08-18 13:18:16 576
原创 Java编程:获取整数m之后的n的素数
首先,要弄明白什么是素数。素数又称质数。一个大于1的自然数,除了1和它自身外,不能被其他自然数整除的数叫做质数。最小的质数是2,它也是唯一的偶数质数。最前面的质数依次排列为:2,3,5,7,11等。比1大但不是质数的数称为合数。 public static boolean isPrimeNumber(int num) { if (num <= 1) { return false; } int count = 0;
2020-07-24 16:46:08 226
原创 关于元素拖拽的JQuery实现
关于元素拖拽的JQuery实现// $(fn)自定义方法(function ($) { $.extend($.fn, { // 拖拽滑动 drag: function () { const $this = $(this), $parent = $this.parent(); const moveLength = $parent.outerWidth() - $this.outerWidth(); // 父容器宽度-滑
2020-07-24 16:37:58 171
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人