码迷,mamicode.com
首页 >  
搜索关键字:int-max    ( 1549个结果
1088
满分20,扣4分,4个答案正确,3个答案错误。 ...
分类:其他好文   时间:2018-10-07 13:02:24    阅读次数:390
java等腰三角形的代码写法
public class EqualsShape { public static void main(String[] args) { //根据给定的方法来输出一个等腰三角 int max = 5; //控制行数 for(int i = 1; i<=5 ; i++) { //控制空格 for (in ...
分类:编程语言   时间:2018-10-04 09:48:47    阅读次数:163
指定范围的随机数
/** * 指定范围的随机数 */ public static int getRandom(int min, int max) { Random random = new Random(); return random.nextInt(max) % (max - min + 1) + min; } ...
分类:其他好文   时间:2018-10-03 00:20:45    阅读次数:163
bzoj2819 nim (树上带修改查询路径异或和)
题目简述: 给定一棵树,n个节点,每个节点表示一个石子堆。有m个操作,操作分两种,第一种修改节点中石子数量,第二种查询两个节点路径上的所有石子堆玩nim游戏,是否必胜。 数据范围:n,m<=500000,石子堆数量<=int_max 分析: 首先需要知道,nim游戏的必胜局面是石子堆的异或和不为0。 ...
分类:其他好文   时间:2018-10-02 20:28:34    阅读次数:143
2014. 青年歌手大奖赛_评委会打分
#include<stdio.h> int main(){ int a[100],n,i,max=a[0],min=a[0]; float sum,ave; scanf("%d",&n); for(i=0;i<n;i++){ scanf("%d",a[i]); sum+=a[i]; } for(i= ...
分类:其他好文   时间:2018-10-01 21:06:56    阅读次数:130
tarjan强连通算法
#include #include using namespace std; const int MAX_N=100; const int MAX_M=10000; struct edge{ int v,next; int len; }E[MAX_M]; int p[MAX_N],eid; void... ...
分类:编程语言   时间:2018-09-29 14:33:24    阅读次数:124
求数组中最大值
/* 所有c语言代码,都是在LoadRunner中运行; */ Action(){ int a[]={12,34,565,23,24,667,89,98};//定义一个int数组; int len;//记录数组元素个数; int max;//所求的最大值; int i;//循环变量;LoadRunn ...
分类:编程语言   时间:2018-09-28 00:05:17    阅读次数:162
求数组中第二大的值
/* 所有c语言代码,都是在LoadRunner中运行; */Action(){ int a[]={12,34,565,23,24,667,89,98};//定义一个int数组; int len;//记录数组元素个数; int max;//所求的最大值; int max_2;//第二大的值; int ...
分类:编程语言   时间:2018-09-28 00:02:54    阅读次数:163
永久化保存 (排行榜的写法list)
1 int max = PlayerPrefs.GetInt("max"), min = PlayerPrefs.GetInt("min"), cen = PlayerPrefs.GetInt("cen"); 2 3 List arr = new List(); 4 arr.Add(max); 5 ... ...
分类:其他好文   时间:2018-09-27 22:54:59    阅读次数:221
Leetcode-908 Smallest Range I(最小差值 I)
1 class Solution 2 { 3 public: 4 int smallestRangeI(vector& A, int K) 5 { 6 int Max = INT_MIN; 7 int Min = INT_MAX; 8 for(auto d:A) 9 ... ...
分类:其他好文   时间:2018-09-23 13:49:26    阅读次数:283
1549条   上一页 1 ... 27 28 29 30 31 ... 155 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!