package com.karl2; public class returnDemo { public static void main(String[] args) { System.out.println("程序开始"); chu(10,5); System.out.println("程序结束"); } public static void chu(int a,int b){ if (b==0){ System.out.println("数据有问题"); return; } int c=a/b; System.out.println("除法结果是:"+c); } }
标签:return,int,System,println,public,out From: https://www.cnblogs.com/Karl-hut/p/17438018.html