public class ArrayForeach{
public static void main(String []args){
int [][]a={{1,2,3},{4,5,6},{7,8,9},{10,11,12}} ;
for(int []row:a)
{
for(int element:row)
System.out.println(element);
}
} }

随机推荐

  1. Sending Email from mailx Command in Linux Using Gmail’s SMTP

    The mailx or mail command in Linux is still providing service for guys like me, especially when we n ...

  2. 使用android.support.design.widget.TabLayout出现java.lang.reflect.InvocationTargetException

    解决方法: 1.在res里面的Values里面的styles定制一个自己的colorPrimary <style name="MyAppTheme" parent=" ...

  3. IOS 控件的生命周期

    ViewController的生命周期包括: Initialize ViewDidLoad ViewWillAppear ViewDidAppear ViewWillDisappear ViewDid ...

  4. phpstorm8 设置及license key

    phpstorm8 license key Learn Programming ===== LICENSE BEGIN ===== 63758-12042010 00000Ryqh0NCC73lpRm ...

  5. select * from table where 1=1

    转自:http://www.dzwebs.net/2418.html 我们先来看看这个语句的结果:select * from table where 1=1,其中where 1=1,由于1=1永远是成 ...

  6. c语言函数指针的理解与使用

    1.函数指针的定义 顾名思义,函数指针就是函数的指针.它是一个指针,指向一个函数.看例子: A) char * (*fun1)(char * p1,char * p2); B) char * *fun ...

  7. 【转】edittext设置点击链接

    I put some ClickableSpan in EditText, unfortunately, that spans are still not clickable. When I clic ...

  8. c++ 格式化printf

    类型为uint64_t的变量,使用printf进行打印时,需要区分操作系统: 64位系统:使用%ld 32位系统:使用%llu #include<stdio.h>#include < ...

  9. 客户端服务端通信protocol

    这个协议不知我在上面耗费了多长时间,也有人问过我咋回事,这个protocol不长,但对于我来说理解起来很费劲,今天回来看看忽然看懂了(80%),只能说不知看了多少遍 其实这些东西应该在来的一个月这样子 ...

  10. linux杀掉80端口线程命令

    80端口被其他程序占用, fuser -k -n tcp 80