码迷,mamicode.com
首页 >  
搜索关键字:if case for    ( 10657个结果
剑指offer系列源码-1+2+3+...+n
题目1506:求1+2+3+...+n 时间限制:1 秒内存限制:128 兆特殊判题:否提交:1261解决:723 题目描述: 求1+2+3+...+n,要求不能使用乘除法、for、while、if、else、switch、case等关键字及条件判断语句(A?B:C)。 输入: 输入可能包含多个测试样例。 对于每个测试案例,输入为一个整数n(1<= n<=100000)。 输出: 对应每个测试案例...
分类:其他好文   时间:2014-12-12 14:56:27    阅读次数:148
Some things about RESUME
1. 介绍Project介绍这个项目的big picture, 比如项目是干什么的,动机是什么,实现的功能是什么。然后介绍具体应用到的技术,所用的语言,开发环境,系统架构,系统设计。在利用一些具体的use case来详细描述这个项目,好比做一个口头的demo。最后说一下这个项目的future wor...
分类:其他好文   时间:2014-12-12 14:51:30    阅读次数:201
spark1.1.0源码阅读-taskScheduler
1. sparkContext中设置createTaskScheduler 1 case "yarn-standalone" | "yarn-cluster" => 2 if (master == "yarn-standalone") { 3 logW...
分类:其他好文   时间:2014-12-11 23:56:29    阅读次数:255
swith case
//switch caseint i=int.Parse(Console.ReadLine());switch(i){case 1:console.WriteLine("星期一");break;case 2:console.WriteLine("星期二");break;case 3:console....
分类:其他好文   时间:2014-12-11 22:12:47    阅读次数:194
switch case 语句
Switchcase语句输入一个年月日,判断是这一年的第几天?Console.WriteLine("请输入年:");intyear=int.Parse(Console.ReadLine());Console.WriteLine("请输入月:");intmonth=int.Parse(Console....
分类:其他好文   时间:2014-12-11 20:40:00    阅读次数:231
运算符 与 分支语句:if ,else if,else;switch case
分支语句:if else if else; switch case--如何使用 if else if else: Console.WriteLine("请你出拳"); --输出【请你出拳】 int a = Convert.ToInt32(Console.ReadLine()); ...
分类:其他好文   时间:2014-12-11 20:35:21    阅读次数:188
【LeetCode】Length of Last Word
Length of Last WordGiven a stringsconsists of upper/lower-case alphabets and empty space characters' ', return the length of last word in the string.I...
分类:其他好文   时间:2014-12-11 17:02:35    阅读次数:133
【读书笔记】《推荐系统(recommender systems An introduction)》第四章 基于知识的推荐
前两章的协同过滤和就内容的推荐都建立在“大量数据”的基础上,运用概率方法来进行计算和预测。不过,在现实生活中,有些物品,如:汽车、房屋、计算机,用户不会频繁的消费。如何在这种情况下对用户进行推荐? 这种case,在现实生活中很常见的就是在淘宝上面用general的query来搜索一些大宗物品,如:相机、电视、空调、等等。这时候淘宝除了给出一些结果,还会给出一些选项,如:品牌、像素、尺寸,...
分类:其他好文   时间:2014-12-11 00:21:48    阅读次数:200
Leetcode: Anagrams
Given an array of strings, return all groups of strings that are anagrams.Note: All inputs will be in lower-case.分析:此题的题意不是很明确,意思重新表述应该是一组string里面,有几个...
分类:其他好文   时间:2014-12-10 22:28:44    阅读次数:294
SQL case when else
先占个坑,sql 版本的swith caseSELECT Oldvote,(CASE WHEN Oldvote=1 THEN (SELECT NOW() from dual)WHEN Oldvote=2 THEN 1WHEN Oldvote=0 THEN 3ELSE 3END) as "numb.....
分类:数据库   时间:2014-12-10 21:03:52    阅读次数:217
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!