上一页 1 ··· 20 21 22 23 24 25 26 27 28 ··· 35 下一页
摘要: product类:package com.lab;public class Product {private int id; // 商品编号 private String name; // 商品名称 private String description; // 商品描述 private float ... 阅读全文
posted @ 2015-05-25 14:31 Run_For_Love 阅读(509) 评论(0) 推荐(0) 编辑
摘要: Map是c++的一个标准容器,她提供了很好一对一的关系,在一些程序中建立一个map可以起到事半功倍的效果,总结了一些map基本简单实用的操作!1.map最基本的构造函数;mapmapstring;mapmapint;mapmapstring;mapmapchar;mapmapchar;mapmapi... 阅读全文
posted @ 2015-05-17 22:02 Run_For_Love 阅读(182) 评论(0) 推荐(0) 编辑
摘要: set提供一个不重复元素的集合,一般不能直接修改元素。因为这样可能会造成重复元素因此必须删除旧元素,再插入新元素。看下面程序:分析每句的功能。#include#includeusing namespace std;int main(){set s;//1s.insert(9);s.insert(3)... 阅读全文
posted @ 2015-05-17 21:09 Run_For_Love 阅读(316) 评论(0) 推荐(0) 编辑
摘要: 这题的最坑的地方就是每步可能会有两种情况,这两情况起初我都单独考虑了,但就是没放在一起考虑。。。wa个不停,果然贪心是一个很考验思维的东西。这里可以这样考虑,在运人的过程中,河的起始岸最后终将剩下一个或者两个 人,并且是用时最大的。所以这个时候就会有两种情况,dp[i]=dp[i-1]+time[i... 阅读全文
posted @ 2015-05-16 20:00 Run_For_Love 阅读(108) 评论(0) 推荐(0) 编辑
摘要: 简单的贪心和高精度运算,主要还是要读懂题。#include"iostream"#include"stdio.h"#include"string"#include"string.h"#include"cmath"#define mx 5005using namespace std;int cnt[15... 阅读全文
posted @ 2015-05-16 19:30 Run_For_Love 阅读(122) 评论(0) 推荐(0) 编辑
该文被密码保护。 阅读全文
posted @ 2015-05-14 21:51 Run_For_Love 阅读(1) 评论(0) 推荐(0) 编辑
摘要: 一、打开和关闭文件#include int main( void ) { FILE* pReadFile = fopen( "E:\\mytest.txt", "r" ); // 打开文件 if ( pReadFile == NULL ... 阅读全文
posted @ 2015-05-13 20:50 Run_For_Love 阅读(2521) 评论(0) 推荐(0) 编辑
摘要: #include static GLsizei iMode = 1;static GLfloat xRot = 0.0f; static GLfloat yRot = 0.0f; int winWidth = 400, winHeight = 200;int iPointNum = 0; int ... 阅读全文
posted @ 2015-05-12 10:41 Run_For_Love 阅读(644) 评论(0) 推荐(0) 编辑
该文被密码保护。 阅读全文
posted @ 2015-05-09 22:22 Run_For_Love 阅读(6) 评论(0) 推荐(0) 编辑
摘要: 转自:http://blog.csdn.net/moxiaomomo/article/details/8056356enums枚举是值类型,数据直接存储在栈中,而不是使用引用和真实数据的隔离方式来存储。(1)默认情况下,枚举中的第一个变量被赋值为0,其他的变量的值按定义的顺序来递增(0,12,3..... 阅读全文
posted @ 2015-05-07 21:06 Run_For_Love 阅读(1001) 评论(0) 推荐(0) 编辑
上一页 1 ··· 20 21 22 23 24 25 26 27 28 ··· 35 下一页