发布时间:2015-11-03 21:56:09
MainActivity 主界面经典的一个下面的选择键来选对应的fragment,在oncreate代码进行分段,首先是获得对应的view(初始化),并对这些view进行修改的部分。1.(1)第一个Fragment是订阅,同时使用ListView,先从服务器来获取订阅信息,使用本地bean数据存放,数据然后给ListView设定Adapter,需要传入Activity和数据,在Ada.........【阅读全文】
发布时间:2015-10-04 12:46:10
//Given inorder and postorder traversal of a tree, construct the binary tree.<br />//<br />//Note:<br />//You may assume that duplicates do not exist in the tree.<br />public class ConstructBinaryTreefromInorderandPostorderTraversal {<br /><br /><br />public static void main(String[] args) {.........【阅读全文】
发布时间:2015-10-04 12:33:07
//Given preorder and inorder traversal of a tree, construct the binary tree.<br />public class ConstructBinaryTreefromPreorderandInorderTraversal {<br /><br /><br />public static void main(String[] args) {<br />// TODO Auto-generated method stub<br /><br /><br />}<br />public TreeNode build.........【阅读全文】
发布时间:2015-10-04 12:31:02
<br /><br />import java.util.ArrayList;<br />import java.util.List;<br />//Triangle My Submissions Question Solution <br />//Total Accepted: 51440 Total Submissions: 184601 Difficulty: Medium<br />//Given a triangle, find the minimum path sum from top to bottom. Each step you may move to .........【阅读全文】
发布时间:2015-10-04 12:28:51
<br /><br />public class MoveZeroes {<br /><br /><br />public static void main(String[] args) {<br />// TODO Auto-generated method stub<br /><br /><br />}<br />public void moveZeroes(int[] nums) {<br />int end=0;<br />int count=nums.length;<br />for(int i=0;i<count;i++){<br />if(num.........【阅读全文】