Although script is producing as required but still can pass pass the three tasks:
-
If you run
./element.sh 1
,./element.sh H
, or./element.sh Hydrogen
, it should outputThe element with atomic number 1 is Hydrogen (H). It's a nonmetal, with a mass of 1.008 amu. Hydrogen has a melting point of -259.1 celsius and a boiling point of -252.9 celsius.
-
If you run
./element.sh
script with another element as input, you should get the same output but with information associated with the given element.
*The rest of the commit messages should start with fix:
, feat:
, refactor:
, chore:
, or test:
codeally@ea7b7efac067:~/project/periodic_table$ git branch
* main
codeally@ea7b7efac067:~/project/periodic_table$ ./element.sh 1
The element with atomic number 1 is Hydrogen (H). It's a nonmetal, with a mass of 1.008 amu. Hydrogen has a melting point of -259.1 celsius and a boiling point of -252.9 celsius.
codeally@ea7b7efac067:~/project/periodic_table$ ./element.sh 5
The element with atomic number 5 is Boron (B). It's a metalloid, with a mass of 10.81 amu. Boron has a melting point of 2075 celsius and a boiling point of 4000 celsius.
codeally@ea7b7efac067:~/project/periodic_table$ ./element.sh H
The element with atomic number 1 is Hydrogen (H). It's a nonmetal, with a mass of 1.008 amu. Hydrogen has a melting point of -259.1 celsius and a boiling point of -252.9 celsius.
codeally@ea7b7efac067:~/project/periodic_table$ ./element.sh b
I could not find that element in the database.
codeally@ea7b7efac067:~/project/periodic_table$ ./element.sh B
The element with atomic number 5 is Boron (B). It's a metalloid, with a mass of 10.81 amu. Boron has a melting point of 2075 celsius and a boiling point of 4000 celsius.
codeally@ea7b7efac067:~/project/periodic_table$ ./element.sh Neon
The element with atomic number 10 is Neon (Ne). It's a nonmetal, with a mass of 20.18 amu. Neon has a melting point of -248.6 celsius and a boiling point of -246.1 celsius.
codeally@ea7b7efac067:~/project/periodic_table$
codeally@ea7b7efac067:~/project/periodic_table$ git log --oneline
f497daf (HEAD -> main) fix: add variable correction reference
2f32276 file deleted
bbaf127 fix: add update code reference
e770012 correction reference
85717e0 feat: file permission reference
9c4af0c feat: add v1 reference
8317149 Initial commit
c6f5695 fix: add fix code reference
331f1eb feat: add if-element print result
5b379c7 feat: add check number reference
4e2665e feaat: add provide element argument
f02f47f feat: add shebang connection reference
02aed76 Initial commit
any idea?