最后
推荐一些系统学习的途径和方法。
每个Web开发人员必备,很权威很齐全的Web开发文档。作为学习辞典使用,可以查询到每个概念、方法、属性的详细解释,注意使用英文关键字搜索。里面的一些 HTML,CSS,HTTP 技术教程也相当不错。
HTML 和 CSS:
开源分享:docs.qq.com/doc/DSmRnRG… package cn.edu.ujn.nk;
import java.util.Scanner; import java.util.regex.Pattern;
/**
- 2016-08-09 --01
- 不要二
- 二货小易有一个W*H的网格盒子,网格的行编号为0
H-1,网格的列编号为0W-1。每个格子至多可以放一块蛋糕,任意两块蛋糕的欧几里得距离不能等于2。 - 对于两个格子坐标(x1,y1),(x2,y2)的欧几里得距离为: ( (x1-x2) * (x1-x2) + (y1-y2) * (y1-y2) )的算术平方根
- 小易想知道最多可以放多少块蛋糕在网格盒子里。
- 输入描述: 每组数组包含网格长宽W,H,用空格分割.(1 ≤ W、H ≤ 1000)
- 输出描述: 输出一个最多可以放的蛋糕数
- 输入例子: 3 2
- 输出例子: 4
- @author SHQ
*/ public class NotTwo {
/**
- @param args */ public static void main(String[] args) { Scanner in = new Scanner(System.in); while (in.hasNextLine()) { String str = in.nextLine(); if (str.length() == 0) { break; } Pattern pattern = Pattern.compile("[ ]+"); String[] arr = pattern.split(str); int w = Integer.parseInt(arr[0]); int h = Integer.parseInt(arr[1]);
System.out.println(notTwoGreed(h, w)); }
}
private static int notTwo(int h, int w) { int cnt = 0; for (int i = 0; i < h; i++) { for (int j = 0; j < w; j++) { if ((i / 2 + j / 2) % 2 == 0) cnt++; } } return cnt; } private static int notTwoGreed(int h, int w) { int [][] a = new int [h][w]; int cnt = 0; for (int i = 0; i < h; i++) { for (int j = 0; j < w; j++) { // 左上 if(i< 2 && j < 2){ a[i][j] = 1; cnt++; // 右上 }else if(i < 2 && j-2 >= 0 && a[i][j-2] != 1){ a[i][j] = 1; cnt++; // 左下 }else if(j < 2 && i - 2 >= 0 && a[i-2][j] != 1){ a[i][j] = 1; cnt++; // 右下 }else if(i >= 2 && j >= 2 && a[i-2][j] != 1 && a[i][j-2] != 1){ a[i][j] = 1; cnt++; } } } return cnt; } }
### **美文美图**

### 紧跟潮流
大前端和全栈是以后前端的一个趋势,懂后端的前端,懂各端的前端更加具有竞争力,以后可以往这个方向靠拢。
这边整理了一个对标“阿里 50W”年薪企业高级前端工程师成长路线,由于图片太大仅展示一小部分
**[开源分享:【大厂前端面试题解析+核心总结学习笔记+真实项目实战+最新讲解视频】](https://docs.qq.com/doc/DSmRnRGxvUkxTREhO)**
