Skip to content

Latest commit

 

History

History
102 lines (80 loc) · 1.1 KB

README.md

File metadata and controls

102 lines (80 loc) · 1.1 KB

Key Value pair

Name: "Aryan Sharma"
1: "This a list"

List

- apple
- mango
- Banana
- banana

or

cities: [new delhi, patna,gujrat]

String and Variables

name: Aryan Sharma
fruit: "Mango"
job: 'Advocate'
age: 65
marks: 10.33
booleanValue: No, N, false, False, FALSE 

Multiline String

Address: |
  01
  Delhi
  India

Single line in multiple line.

message: >
  This all
  will be in a single
  line

Nested Mapping

names: aryan
role:
  age: 22
  job: student

Nested Sequence

-
  - mango
  - apple
  - banana
-
  - marks
  - roll
Specify the data type
# Integer
Zero: !!int 0
positiveNumber: !!int 45
negativeNumber: !!int -45
hexa: !!int 0x45

# Float
mark: !!float 56.55
infinity: !!float .inf
not a num: .nan
itNot: !!bool false

# String
string: !!str "hello"

# Null
surname: !!null #null or NULL ~ 
~: this a null key

# Exponential Numbers
myNum: 6.22ES56

# Dates and time
date: !!timestamp 2002-01-02
no Time zone: 2012-12-15T02:59:43
India Time: 2012-12-15T02:59:43 +5:30