题目是选出c个连续的囚犯,而且囚犯的级别不能大于t#include using namespace
std;int main(){ int n,t,c; cin >> n >> t >> c; int a,cnt = 0,
res =0;; for(int i = 0 ; i...
分类:
其他好文 时间:
2014-05-04 12:14:55
阅读次数:
340
1.状态管理(用户登录)phpAsp===》cookie(客户端)本地JSP
session(服务器)2.setcookie("mycookie",$user,time()+1800);默认有前两个值 if($row[0]){
setcookie("mycookie",$user,time()+1....
分类:
其他好文 时间:
2014-05-04 12:11:18
阅读次数:
383
#pragma once#include namespace stds { class tool
{ public: std::string ws2s(const std::wstring& ws) { std::string curLocale =
setlocale(LC_ALL...
分类:
其他好文 时间:
2014-05-03 22:25:17
阅读次数:
318
#include "stdafx.h"#include "windows.h" #include
"imm.h" #include "stdio.h" #include #include #include #include #include
"tool.h"#include #includ...
分类:
其他好文 时间:
2014-05-03 22:14:08
阅读次数:
409
今天倒持了 几个小时!
愣是 没有明白 ,为什么我的JSP的第一行没有代码? 还是报错!
错误是:
Description
Resource Path
Location Type
Syntax error, insert ")" to complete Expression
left.jsp /qyrs/WebRoot/admin/iframe
line 1 Clie...
分类:
其他好文 时间:
2014-05-03 21:48:53
阅读次数:
572
题目链接:1372 - Log Jumping
题意:给定一些n个木板的起始位置和长度k,相重叠的木板可以互相跳跃,求能构成环的最大数量。
思路:先按起始位置排序,然后每次多一个木板就去判断他和前一个和前前一个能不能互相跳跃,如果可以的话就可以多加上这个木板。
代码:
#include
#include
#include
using namespace std;
#define ma...
分类:
其他好文 时间:
2014-05-03 21:44:03
阅读次数:
247
第1部分 重新认识C语言C语言中常用的文件操作函数总结及使用方法演示代码 1. C语言中常用的文件操作函数总结(1) fopen作用:打开文件。表头文件:#include 定义函数:FILE *fopen(const char *path, const char *mode);函数说明:参数path字符串包含欲打开的文件路径及文件名,参数mode字符串则代表着流形态。mode有下列几种形态字符串:...
分类:
其他好文 时间:
2014-05-03 21:38:17
阅读次数:
279
概述:
过滤器是Servlet2.3以上新增加的一个功能,其技术也是非常强大的。通过Filter技术可以对WEB服务器的文件进行拦截,从而实现一些特殊的功能。在JSP开发应用中也是必备的技能之一。Filter可以改变一个request(请求)和修改一个response(响应)。Filter不是一个Servlet,它不能产生一个response,它能够在一个requsst到达Servlet之前预处...
分类:
其他好文 时间:
2014-05-03 21:30:26
阅读次数:
291
【分析】
【伪代码】
【运行过程】
【代码】
/*********************************
* 日期:2014-04-01
* 作者:SJF0115
* 题目:快速排序
**********************************/
#include
#include
using namespace...
分类:
其他好文 时间:
2014-05-03 21:17:50
阅读次数:
476
//非递归遍历一棵树 需要借助栈
#include
#include
struct Tree
{
int nValue;
Tree *pLeft;
Tree *pRight;
};
struct Stack
{
Tree *root;
Stack *pNext;
};
Stack *pStack = NULL;
void push(Tree *root)
{
St...
分类:
其他好文 时间:
2014-05-03 20:55:41
阅读次数:
325