Java interview questions (basic part)

1、Can a.Java source file include multiple classes (not internal classes)? What are the restrictions?     There can be multiple classes, but only one public class, and the public class name must be consistent with the file name. 2、JavaDo you have goto?   javaThe reserved word is not used in Java now. 3、Let’s talk about the difference between &amp and & &amp.     &And & amp; & amp; can be used as logic and operators, representing logic and (and), when the result of the expression on both sides of the operator is true, the entire operation re...

The password behind a complete Java Web project

Preface Recently I have done several Java Web projects myself, including a company business project and a personal fun project. Write a note summarizing the gains and listing the skills and knowledge needed to do the whole process of doing the project, bringing to you the skills and knowledge that have not really touched the full Java Web.Students of the project have a more complete perspective, providing a so-called “overall situation view”, so that students can learn more targeted. Of course, the example items used here are very elementary and simple, so the gods don’t hav...

Java intermediate buffer variable mechanism

int count = 0 ; int num = 0 ; int i ; for (i = 0 ; i <= 100; i++){ num +=i;// countFirst assign, each assignment is 0, after + +, intermediate buffer variable mechanism. count = count++ ;//Running count++ is valid value every time.// count++; System.out.println(num+ "*" + count +" = "+ count * num ); } System.out.println( "Finally: "+ count * num";Running result  

Java- reflection

//Test class 1 package com.test; 2 3 public class Student { 4 5 private int stuNum; 6 private String stuName; 7 private String stuClass; 8 9 private Student(int stuNum) { 10 this.stuNum = stuNum; 11 } 12 Student(int stuNum, String stuName) { 13 this.stuNum = stuNum; 14 this.stuName = stuName; 15 } 16 public Student() { 17 18 } 19 public Student(int stuNum, String stuName, String stuClass) { 20 this.stuNum = stuNum; 21 this.stuName = stuName; 22 this.stuClass = stuClass; 23 } ...