JSON Assignment– 1

Basic Questions

  1. Create a JSON string for a student with name, age, and course.
  2. Write a JSON object to store a book with title, author, and price.
  3. Create a JSON array with 5 city names.
  4. Write a JSON object to store an employee with id, name, and isActive (boolean).
  5. Create a JSON object for a product with a nested category object.
  6. Write a JSON object to store a user’s hobbies as an array.
  7. Create a JSON object where a student has a nested address object.
  8. Write a JSON array containing 3 objects, each with id and name.
  9. Create a JSON object for a company with an array of 2 employees.
  10. Write a JSON object for a person having an array of skills.
  11. Create a JSON object for a product that stores multiple images in an array.
  12. Write a JSON object for a movie with title, year, and actors (array).
  13. Create a JSON object for a car with brand, model, year, and features (array).
  14. Write a JSON object for a person’s phone numbers as an array of objects.
  15. Create a JSON object for a course with an array of multiple students.
  16. Write a JSON object for a laptop with name, price, and a nested specifications object.
  17. Create a JSON object for a restaurant menu with an array of food items {name, price}.
  18. Write a JSON object for a football team with a list of players.
  19. Create a JSON object for a teacher with subjects (array) and a nested details object.
  20. Write a JSON object for an order with orderId, customer, and an items array.

Intermediate Level

  1. Write a JSON object for a student with subjects and their marks.
  2. Create a JSON object for a flight with flightNo, departure, arrival, and a nested array of passengers.
  3. Write a JSON object for a hospital with multiple doctors and their patients.
  4. Create a JSON object for an online store with a products array, each having id, name, price, and stock.
  5. Write a JSON object for a cricket match with team1 and team2 player arrays.
  6. Create a JSON object for a music album with albumName, releaseYear, and a songs array.
  7. Write a JSON object for a classroom with a students array of {rollNo, name, marks}.
  8. Create a JSON object for a bank account with accountNo, holderName, and a transactions array.
  9. Write a JSON object for a hotel with a rooms array of {roomNo, type, price, isAvailable}.
  10. Create a JSON object for a library with multiple books and their authors.
  11. Write a JSON object for a university with departments (array) and multiple professors per department.
  12. Create a JSON object for an online course with title, instructor, students (array), assignments (array).
  13. Write a JSON object for a company with multiple departments and employees in nested structure.
  14. Create a JSON object for an e-commerce cart with multiple products and totalAmount.
  15. Write a JSON object for a social media post with postId, user, content, likes, comments (array).
  16. Create a JSON object for a delivery order with orderId, customer, address, and deliveryStatus.
  17. Write a JSON object for a bank loan with loanId, customerName, loanAmount, and installments (array).
  18. Create a JSON object for a school timetable with nested arrays.
  19. Write a JSON object for a gaming leaderboard with rank, playerName, score.
  20. Create a JSON object for a shopping wishlist with user and items (array of products).

Advanced Questions

  1. Create a JSON object for an e-commerce website order history with customers, orders, and products.
  2. Write a JSON object for a hospital management system with doctors, patients, appointments, and prescriptions.
  3. Create a JSON object for an airline system with flights, passengers, tickets, and baggage.
  4. Write a JSON object for a sports tournament with multiple matches, teams, and scores.
  5. Create a JSON object for a school system with students, teachers, exams, and results.
  6. Write a JSON object for a real estate system with properties, owners, buyers, and transactions.
  7. Create a JSON object for a movie database with movies, directors, actors, and reviews.
  8. Write a JSON object for a university system with faculties, departments, courses, and enrolled students.
  9. Create a JSON object for an e-commerce admin panel with users, orders, refunds, and payments.
  10. Write a JSON object for a travel booking system with users, trips, hotels, flights, an