By GokiSoft.com|
19:28 10/04/2024|
Java Basic
Java Basic- Tạo dự án đầu tiên & phát hành dự án
Yêu cầu :
Viết chương trình hiển thị thông tin cá nhân của bạn bao gồm (tên, tuổi, địa chỉ, email, sđt)
Tạo file jar cho dự án -> chạy dự án bằng lệnh cmd (window) hoặc terminal trong macosx
Tags:
Phản hồi từ học viên
5
(Dựa trên đánh giá ngày hôm nay)
![le anh tuan [java1_online]](https://www.gravatar.com/avatar/0c79bbaaa43a903799a613fb8a163e0a.jpg?s=80&d=mm&r=g)
le anh tuan
2022-08-31 11:09:54
package javabasic;
public class JavaBasic {
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
System.out.println("Tên: Lê Anh Tuấn");
System.out.println("Tuổi: 26");
System.out.println("Địa chỉ: Cần thơ");
System.out.println("email: tuan@gmail.com");
System.out.println("SĐT: 0999999999");
}
}
![Hoàng Anh [C2010G]](https://www.gravatar.com/avatar/e73c31efff649e599b1e4320b6bfb1a9.jpg?s=80&d=mm&r=g)
Hoàng Anh
2022-06-17 13:41:02
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package c2108l;
import java.util.Scanner;
/**
*
* @author Hoàng Anh
*/
public class bai1 {
public static void main(String[] args) {
Scanner input = new Scanner(System.in);
System.out.println("Nhập tên: ");
String name = input.nextLine();
System.out.println("Nhập tuổi: ");
int age = Integer.parseInt(input.nextLine()); //sử dụng nextLine thay vì nextInt đẻ k bị trôi lệnh
System.out.println("Nhập địa chỉ: ");
String address = input.nextLine();
System.out.println("Nhập email: ");
String email = input.nextLine();
System.out.println("Nhập số điện thoại: ");
float phonenumber = input.nextFloat();
System.out.format(" tên: %s\n tuổi: %d\n địa chỉ: %s\n email: %s\n số điện thoại: %f", name,age,address,email,phonenumber);
}
}
![Trần Việt Đức Anh [C2010L]](https://www.gravatar.com/avatar/caee507e11365ca2cf5068cbea5c740a.jpg?s=80&d=mm&r=g)
Trần Việt Đức Anh
2021-07-01 11:01:33
/*
Vi?t ch??ng tr�nh hi?n th? th�ng tin c� nh�n c?a b?n bao g?m (t�n, tu?i, ??a ch?, email, s?t)
T?o file jar cho d? �n -> ch?y d? �n b?ng l?nh cmd (window) ho?c terminal trong macosx
*/
package Lession1;
/**
*
* @author Tran Viet Duc Anh
*/
public class Test_JAR {
public static void main(String[] args) {
String name = "Tran Viet Duc Anh";
int age = 20;
String addr = "487 Truong Chinh, Nam Dinh";
String email = "ge1362001@gmail.com";
String pnum = "083xxxxx67";
System.out.println("Fullname: " + name);
System.out.println("Age: " + age);
System.out.println("Address: " + addr);
System.out.println("Email: " + email);
System.out.println("Phone Number: " + pnum);
}
}
![Hoàng Anh [community,C2010G]](https://www.gravatar.com/avatar/e73c31efff649e599b1e4320b6bfb1a9.jpg?s=80&d=mm&r=g)
Hoàng Anh
2021-06-29 15:27:24
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package javaapplication4;
import java.util.Scanner;
/**
*
* @author Bom1
*/
public class baitap3 {
public static void main(String[] args) {
Scanner add = new Scanner(System.in);
Scanner input = new Scanner(System.in);
System.out.println("Nhập tên :");
String name = add.nextLine();
System.out.println("Nhập tuổi:");
int age = input.nextInt();
System.out.println("Nhập địa chỉ:");
String adress = add.nextLine();
System.out.print("Nhập email: \n");
String email = add.nextLine();
System.out.println("Nhập số điện thoại:");
int phonenumber = input.nextInt();
System.out.format("Tên: %s ,Tuổi: %d ,Địa chỉ: %s ,email: %s ,Số điện thoại: %d", name,age,adress,email,phonenumber);
}
}
![Đỗ Phan Hà [community,C2010L]](https://www.gravatar.com/avatar/644556c9d81d43016df661abe38dff3a.jpg?s=80&d=mm&r=g)
Đỗ Phan Hà
2021-06-29 13:55:18
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package aptech;
/**
*
* @author ZZoukertic
*/
public class Main {
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
// TODO code application logic here
String fullname = "Do Phan Ha";
int age = 18;
String phoneNum ="097393xxxx";
System.out.println("Ho va ten: " + fullname + "\nTuoi: " + age + "\nSo Dien Thoai: " + phoneNum);
}
}
![hieuvm0512 [community,C2010L]](https://www.gravatar.com/avatar/0cacbf21fed14b987a433597d2edc14f.jpg?s=80&d=mm&r=g)
hieuvm0512
2021-06-29 13:51:01
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package com.mycompany.jv1;
import java.util.Scanner;
/**
*
* @author vuive
*/
public class stu {
public static void main(String[] agrs){
System.out.println("Nhap Ten: ");
Scanner input = new Scanner(System.in);
String ten = input.nextLine();
System.out.println("Nhap tuoi: ");
int tuoi = input.nextInt();
input.nextLine();
System.out.println("Nhap email: ");
String email = input.nextLine();
System.out.println("Nhap sdt: ");
int sdt = input.nextInt();
System.out.format("Sinh vien :%s \n tuoi:%d \n email:%s \n SDT: 0%d", ten,tuoi,email,sdt );
}
}
![Nguyen Trung Kien [community,C2010G]](https://www.gravatar.com/avatar/598b6cbd59c38ba0404dfa2129befa0a.jpg?s=80&d=mm&r=g)
Nguyen Trung Kien
2021-06-28 14:57:49
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package bt973;
import java.util.Scanner;
/**
*
* @author TrangAnh Lptop
*/
public class Main {
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
// TODO code application logic here
String ten;
int tuoi;
String diachi;
String email;
String sdt;
Scanner scan = new Scanner(System.in);
System.out.println("Nhap ten: ");
ten = scan.nextLine();
System.out.println("Nhap dia chi: ");
diachi = scan.nextLine();
System.out.println("Nhap tuoi: ");
tuoi = Integer.parseInt(scan.nextLine());
System.out.println("Nhap email: ");
email = scan.nextLine();
System.out.println("Nhap sdt: ");
sdt = scan.nextLine();
System.out.println("Ten : " + ten);
System.out.println("dia chi : " + diachi);
System.out.println("tuoi : " + tuoi);
System.out.println("email : " + email);
System.out.println("sdt : " + sdt);
}
}
![Đặng Trần Nhật Minh [T2008A]](https://www.gravatar.com/avatar/ee8dc5a777ad26f3a962e86c233437cf.jpg?s=80&d=mm&r=g)
Đặng Trần Nhật Minh
2021-01-22 09:13:33
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package javalesson2;
/**
*
* @author W10-2004
*/
public class ex01 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
String fullName = "Minh Dang";
int age = 18;
String phoneNum = "091 286 0510";
System.out.println("Full Name: " + fullName + "\nAge: " + age + "\nPhone Number: " + phoneNum);
}
}
![Nguyễn Anh Vũ [T2008A]](https://www.gravatar.com/avatar/8863d24ed74b396082becbc4db8331fd.jpg?s=80&d=mm&r=g)
Nguyễn Anh Vũ
2021-01-21 14:57:50
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package bt;
/**
*
* @author Admin
*/
public class T2008A {
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
// TODO code application logic here
String name = "NGUYEN ANH VU";
int age = 20;
String address = "HA NAM";
String email = "vunath2007034@fpt.edu.vn";
String phonenumber = "0964657860";
}
//Hien thi
System.out.println("Ten: " + Name);
System.out.println("Tuoi: " + Age);
System.out.println("Dia Chi: " + Address);
System.out.println("Email: " + Email);
System.out.println("SDT: " + Phonenumber);
}
![Đức Sơn [T2008A]](https://www.gravatar.com/avatar/d2b971b7bc54e4a9689c3e2240f27949.jpg?s=80&d=mm&r=g)
Đức Sơn
2021-01-21 13:14:10
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package project2;
/**
*
* @author ADMIN
*/
public class Project2 {
/**
* @param args the command line arguments
*/
public static void main(String[] args) {
// TODO code application logic here
System.out.println("Ten: Le Cong Duc");
System.out.println("Tuoi: 19");
System.out.println("Dia chi: cau giay");
System.out.println("email: Duc1234@gmail.com");
System.out.println("sdt: 0965432678");
}
}