手记

Library System Design

com.imoocBooks {
    String (numString name){
        .= num.= name}

}


com.imoocjava.util.ScannerLibrarySystem {
    Books[] = Books[](String[] args) Exception {
        LibrarySystem system = LibrarySystem()system.start()}

    () Exception {


        fillbooksArray()UserInput01()}



    (Books[] books) {
        books[] = Books()books[] = Books()books[] = Books()books[] = Books()books[] = Books()books[] = Books()books[] = Books()books[] = Books()books[] = Books()books[] = Books()}

    () Exception {
        {
            System..println()Scanner scan = Scanner(System.)Input = scan.nextInt()(Input==){
                InputName()}(Input==){
                InputIndex()}{
                System..println()UserInput01()}
        } (Exception e) {
            System..println()UserInput01()}
    }

    () Exception {
        {
            System..println()Scanner scan = Scanner(System.)String Input01 = scan.next()isMatch = (i = i < .i++) {
                (Input01.equals([i].)){
                    System..println(+ [i].+ + [i].)isMatch = }
            }
            (isMatch == ){
                System..println()InputName()}
        } (Exception e) {
            System..println()InputName()}
    }

    () Exception {
        {
            System..println()Scanner scan = Scanner(System.)Input02 = scan.nextInt()isMatch = (i = i < .i++) {
                (Input02 == [i].){
                    System..println(+ [i].+ + [i].)isMatch = }
            }
            (isMatch == ){
                System..println()InputIndex()}
        } (Exception e) {
            System..println()InputIndex()}
    }
}



运行效果

1人推荐
随时随地看视频
慕课网APP