Sightseeing tour 题目链接:http://poj.org/problem?id=1637 Description: The city executive board in Lund wants to construct a sightseeing tour by bus in Lun ...
分类:
其他好文 时间:
2019-01-06 21:53:40
阅读次数:
179
一.程序交互 1.数字类型 你需要考虑单双的配合(特殊情况,其他情况下随意) 1 name = input('Name:') 2 age = input('Age:') 3 job = input('Job:') 4 hometown = input('Hometown:') 5 6 info='' ...
分类:
编程语言 时间:
2019-01-06 20:02:38
阅读次数:
204
goods = [{"name": "电脑", "price": 1999}, {"name": "鼠标", "price": 10}, {"name": "游艇", "price": 20}, {"name": "美女", "price": 998}, ] 要求: 1:页面显示 序号 + 商品名称 ...
分类:
其他好文 时间:
2019-01-06 16:36:18
阅读次数:
204
NIO概述 什么是NIO? Java NIO(New IO)是一个可以替代标准Java IO API的IO API(从Java 1.4开始),Java NIO提供了与标准IO不同的IO工作方式。 Java NIO: Channels and Buffers(通道和缓冲区) 标准的IO基于字节流和字符 ...
分类:
其他好文 时间:
2019-01-06 14:31:40
阅读次数:
161
Given two binary strings, return their sum (also a binary string). The input strings are both non-empty and contains only characters 1 or 0. Example 1 ...
分类:
其他好文 时间:
2019-01-06 13:32:20
阅读次数:
138
Given a non-negative integer N, your task is to compute the sum of all the digits of N, and output every digit of the sum in English. Input Specificat ...
分类:
其他好文 时间:
2019-01-06 11:53:55
阅读次数:
193
题目的大意为给定一个长度为2n的数组,把数组分为n对,使从1到n的min(ai,aj)的总和最大。 比如: 拿到这道题,发现排序后比较好解决。 可以发现排序后相邻两个元素分组,把奇数位置的元素相加即为所求。 java public int arrayPairSum(int[] nums) { Arr ...
分类:
其他好文 时间:
2019-01-06 10:45:54
阅读次数:
166
最近项目有一个空气检测仪,需要得到空气检测仪的实时数据,保存到数据库当中。根据了解得到,硬件是通过rs485进行串口通讯的,需要发送16进制命令给仪器,然后通过轮询来得到数据。 需要先要下载RXTX的jar包,win64位下载地址:http://pan.baidu.com/s/1o6zLmTc);将 ...
分类:
编程语言 时间:
2019-01-06 01:09:29
阅读次数:
231
一、基础 1.python后缀名位.py 2.两种执行方式 a.python解释器 py文件路径 b.进入python解释器,实时输入并获取到执行结果 3.Linux系统中: 文件内部 执行用 ./2.py 4.编码 用python3无需关注 用python2执行输出中文时,要加申明 注:ascll ...
分类:
编程语言 时间:
2019-01-06 00:03:42
阅读次数:
239