Tuesday, 20 June 2023

Demystifying JSON: Understanding Simple JSON, JSON Arrays, and JSON Objects

 


 
Top API Interview Question 1-10


 

What is JSON Schema and How to Perform JSON Schema Validation using Rest Assured? 

How to read test data from JSON file ? 

 

JSON (JavaScript Object Notation) is a lightweight data-interchange format that is widely used for transmitting and storing data. It is easy for humans to read and write, and it is also easy for machines to parse and generate.

Here are examples of simple JSON, JSON array, and JSON objects:

 

Simple JSON: 

 

Simple JSON consists of key-value pairs where the values can be of different data types such as strings, numbers, booleans, null, or nested JSON objects or arrays.

Example:

{
"name": "John Doe",
"age": 30,
"isStudent": false,
"address": null
}

 

In this example, we have a simple JSON object with four key-value pairs. The "name" key has a string value, "age" has a numeric value, "isStudent" has a boolean value, and "address" has a null value.

 

Selenium Interview Questions and answers

Java Coding Interview Questions and Answers

GIT Interview Questions and Answers

 

JSON Array: 

 

A JSON array is an ordered list of values enclosed in square brackets ([]). The values in the array can be of any data type, including strings, numbers, booleans, objects, or even nested arrays.

Example:


{ "fruits": ["apple", "banana","orange"] }

In this example, we have a JSON object with a key "fruits" that holds a JSON array. The JSON array contains three string values: "apple", "banana", and "orange".

 

JSON Objects: 

 

JSON objects are unordered collections of key-value pairs enclosed in curly braces ({}). The values can be of any data type, including strings, numbers, booleans, null, other JSON objects, or arrays.

Example:

{
"person": {
  "name": "Jane Smith",
  "age": 25,
  "isStudent": true,
  "address": {
    "street": "123 Main St",
    "city": "New York",
    "country": "USA"
  },
  "languages": [
    "English",
    "French",
    "Spanish"
  ]
}
}

In this example, we have a JSON object with a key "person" that holds another JSON object. The inner JSON object represents a person's information. It includes keys like "name", "age", "isStudent", "address", and "languages". The "address" key holds another JSON object representing the person's address, and the "languages" key holds a JSON array of strings representing the person's known languages.

These examples illustrate the basic structure and usage of simple JSON, JSON arrays, and JSON objects. JSON provides a flexible and widely adopted format for data interchange in various programming languages and applications.

 ⭐️⭐️⭐️⭐️⭐️


📌YouTube channel:
https://lnkd.in/gHJ5BDJZ

📌Telegram group:
https://lnkd.in/gUUQeCha

📌Schedule 1:1 call:
https://lnkd.in/ddayTwnq

📌Medium blogs:
https://lnkd.in/gkUX8eKY
*******************************************************************
For any doubts or career guidance from me, reach out here: https://topmate.io/sidharth_shukla

********************************************************************

Do remember that knowing Linux is one of the most important aspect to work as an SDET.

Basic Linux Commands for Automation QA


****************************************

 SDET Interview Question and Answers

TestNG Interview questions and answers

Jenkins Interview Questions and Answers

Appium Interview Questions and Answers

Selenium Interview Questions and answers

Java Coding Interview Questions and Answers

GIT Interview Questions and Answers


************************************************

✍️AUTHORLinkedIn Profile

************************************************

Learn (API-Microservice)Testing+ Selenium UI Automation-SDET with Self Paced Videos prepared by FAANG employees and LIVE Doubt Session 

SDET TRANING VIDEOS AVAILABLE with Live Doubt Session(course-1 below,API TRaining Videos With Class Notes and Coding Set) and (API++Mobile+UI, course-1 & 2 below) Check Training Page for Course Content or reach out @whatsapp +91-9619094122. 
This includes classnotes, 300+ interview questions, 3 projects, Java Coding question set for product companies along with career guidance from FAANG employees for Automation and SDET.

For more details whatsapp : https://lnkd.in/dnBWDM33

*************************************************



SeleniumWebdriver Automation Testing Interview Questions:

https://automationreinvented.blogspot.com/search/label/SeleniumWebdriver

API Testing Interview Question Set:

https://automationreinvented.blogspot.com/2022/03/top-80-api-testing-interview-questions.html

DevOps Interview Q&A:

https://automationreinvented.blogspot.com/2021/11/top-11-devops-interview-questions-and.html 

Kubernetes Interview Question Set

https://automationreinvented.blogspot.com/search/label/Kubernetes

Docker Interview Question Set

https://automationreinvented.blogspot.com/Docker

Linux Interview question Set

https://automationreinvented.blogspot.com/search/label/Linux

Automation Testing/SDET Framework Design

https://automationreinvented.blogspot.com/search/label/FrameworkDesign

Java Related Interview Question Set

https://automationreinvented.blogspot.com/search/label/Java

GIT Interview Question Set:

https://automationreinvented.blogspot.com/2021/09/top-40-git-interview-questions-and.html

Coding Interview Question Set:

https://automationreinvented.blogspot.com/search/label/Coding%20Questions

Mobile Testing Interview Question Set:

https://automationreinvented.blogspot.com/search/label/Mobile%20Testing

Python Interview Question Set for QAE - SDET - SDE:

https://automationreinvented.blogspot.com/search/label/Python

 

 

No comments:

Post a Comment

All Time Popular Posts

Most Featured Post

Introduction to Web Testing with Playwright

  Introduction to Web Testing with Playwright 📌  Telegram Group:  https://t.me/+FTf_NPb--GQ2ODhl 📌  YouTube channel:  https://lnkd.in/gGUG...