在arduino1.0之前的版本 Serial.flush()的作用是是清空串口缓存( dropping received incoming data).但在1.0之后的版本 Serial.flush()的作用调整为了等待串口数据传送完毕(Waits for the transmission of outgoing serial data to complete.)(引用自http://arduino.cc/en/Serial/Flush). 因为我在使用wifibee的过程中,如果既想用Ser
不用泛型只能操作某种类型进行反转 代码如下: package com.swift.fanxing; import org.junit.Test; public class RenyiReverse { @Test public void test() { int arr[]=new int[] {1,10,6,9,2}; reverse(arr); } public void reverse(int[] arr) { for(int i=0;i<arr.length/2;i++) { int t