/home/caleb/ASDV-Java/lab6_CalebFontenot/src/main/java/com/calebfontenot/lab6_calebfontenot/Lab6_CalebFontenot.java |
/* * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license * Click nbfs://nbhost/SystemFileSystem/Templates/Project/Maven2/JavaApp/src/main/java/${packagePath}/${mainClassName}.java to edit this template */ package com.calebfontenot.lab6_calebfontenot; import java.util.Scanner; /** * * @author caleb */ public class Lab6_CalebFontenot { public static void main(String[] args) { System.out.println("Please type a positive number: "); Scanner scan = new Scanner(System.in); int number = scan.nextInt(); if (number >= 0) { System.out.println("You typed a positive number! It was number " + number + "!"); } } }