CodeWithMMD

Home
Challenges
Output:
  • createUserObject

    4 months ago

    Create a function createUserObject that returns an object with properties name and age.

  • factoryFunction

    4 months ago

    Create a factory function createPerson that takes name and age, and returns an object with those properties.

  • constructorFunction

    4 months ago

    Create a constructor function Person with name and age properties. Create a new person and log it.

  • addProperty

    4 months ago

    Create an object and then dynamically add a property called 'country' to it and log the object.

  • checkConstructor

    4 months ago

    Create a function checkConstructor that logs the constructor of an object created with {}.

  • functionIsObject

    4 months ago

    Create a function myFunc and log its typeof and check if it has a name property.

  • valueVsReference

    4 months ago

    Create two object variables pointing to the same object. Modify one and log both.

  • enumerateProperties

    4 months ago

    Create an object and use for...in to log all its property names.

  • cloneObject

    4 months ago

    Create an object and make a shallow clone using spread operator, then log the clone.

  • destructObject

    4 months ago

    Create an object with name and age, destructure it, and log both values.

  • mathObject

    4 months ago

    Create a function that logs Math.PI and the rounded value of 4.7.

  • stringMethods

    4 months ago

    Create a function that uses .toUpperCase() and .includes() on a string and logs the results.

  • dateObject

    4 months ago

    Create a function that logs the current year using the Date object.

Mohammad Fallah

Crafting digital experiences with passion, precision, and a touch of magic

© 2025 CodeWithMMD. All right reserved.

Built with Nextjs