码迷,mamicode.com
首页 >  
搜索关键字:do while循环    ( 14864个结果
Do you really know what means initialization? “初始化 定义 赋值” 之间的联系与区别
“初始化 定义 赋值” 之间的联系与区别              本来很早之前就想写个blog,说说这三个家伙的区别和联系,三者之间各种联系,很难比较清楚的讲明白,感觉当时好像分析思路还不够“完整”。今天遇到别人抛出来的一个问题。根本的问题是和初始化和赋值有关系,于是留下这个blog。 #include struct _ANIBMP { int FirstNu...
分类:其他好文   时间:2014-07-22 23:04:54    阅读次数:384
玩转web之servlet(六)---session介绍及简单使用(登录验证中保存信息)
在浏览器与服务器进行交互时,往往需要把涉及到的一些数据保存下来,这时就需要使用cookie或session进行状态管理。 这篇文章先来说说session怎么用,首先在servlet中创建一个session来保存信息,举个例子,在做登陆验证时,如果登陆成功,需要将用户的信息保存到session中,怎么保存呢?下面给出代码: public class Login_Do extends HttpS...
分类:Web程序   时间:2014-07-22 23:03:52    阅读次数:355
Lua基础(二)——表
表 a = { } b = { x = 1, ["hello, "] = "world!" } a.astring = "ni, hao!" a[1] = 100 a["a table"] = b function foo() end function bar() end a[foo] = bar --分别穷举表a和b for k, v in pairs(a) do print(k, "=>",...
分类:其他好文   时间:2014-07-22 23:00:33    阅读次数:261
[递推dp] zoj 3747 Attack on Titans
题目链接: http://acm.zju.edu.cn/onlinejudge/showProblem.do?problemId=5170 Attack on Titans Time Limit: 2 Seconds      Memory Limit: 65536 KB Over centuries ago, mankind faced a new enemy, th...
分类:其他好文   时间:2014-07-22 23:00:16    阅读次数:536
整数加减法练习
程序自动产生随机数(srand 设置种子为系统时间,以保证每次运行程序产生的随机数有差别 ),然后用户输入结果,程序判断用户输入是否正确减法运算时要保证随机产生的a要大于b(用while循环判断,当然前提条件是用户选择的为减法运算,这里只保证式子产生的结果为非负整数)。#include #inclu...
分类:其他好文   时间:2014-05-01 23:59:45    阅读次数:499
hdu 1074 Doing Homework
Problem DescriptionIgnatius has just come back school from the 30th ACM/ICPC. Now he has a lot of homework to do. Every teacher gives him a deadline o...
分类:其他好文   时间:2014-05-01 20:49:40    阅读次数:563
2014年5月份
这个五月份,what will to do?1、软件设计师考试2、英语六级考试3、暑假的实习前几天的教训,不会忘记,现在总会有那么一种模式叫做“许冰模式”。所有的语言都是苍白的,即使我们可以尽情的洋洋洒洒的描述,但是,最后提取的关键字,就是那几个名词,刺眼的名词,我会用实际行动去表达。还是那一句:做...
分类:其他好文   时间:2014-05-01 19:56:40    阅读次数:334
Leetcode | Palindrome Number
Determine whether an integer is a palindrome. Do this without extra space.Some hints:Could negative integers be palindromes? (ie, -1)If you are thinki...
分类:其他好文   时间:2014-05-01 19:48:19    阅读次数:344
Leetcode:Rotate Image 旋转图片
You are given an n x n 2D matrix representing an image. Rotate the image by 90 degrees (clockwise). Follow up: Could you do this in-place? 刚开始没有思路,但是自己举了几个简单的栗子才看出规律:需要一圈儿一圈儿的变换位置。有两层for循环:外...
分类:其他好文   时间:2014-05-01 18:33:34    阅读次数:359
Lua chapter 1
1. 调用其他的.lua文件   dofile("xx.lua");   2. 避免用 "_VERSION"这类的标识符,Lua将这类标识符用作特殊用途,通常保留"_"作为”哑变量“ 3. Lua的一些保留字:    do in local nil until 等     4. 注释:-- 表示行注释   --[[ ... ]] 表示块注释 一般的块注释这样写: --[[ ...
分类:其他好文   时间:2014-04-30 22:34:38    阅读次数:270
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!