Skip to content

frankmawuli/js-for-react-native-11232324

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 

Repository files navigation

DCIT 202 Mobile Application Development Assignment 1

Student ID: 11232324

This repository contains solutions for DCIT 202's assignments.

Tasks

Task 1: Creating a javascript file named arrayManipulation .js

  • Description: In this task we were instructed to write a function called processArray.
  • File(s): [arryManipulation.js]
  • Usage: With the procesArray function it takes in an array of integers as an argument. Later the .map() function is used to create a new array based on certain condition.
  • When the number in the array is an even number it multiplies it by two and when it is odd it multiplies by 3

Task 2: Creating a format string function

  • Description: In task2 we were require to add a function formatArrayStrings in arrayManipulation .js
  • File(s): [arrayManipulation.js]
  • Usage: with the formatArrayStrings it takes an array of strings and and the output of the processedArray as an argument it returns the stringArray with the .map() method acting on it.
  • The .map() method takes in an argument of elements and inddex

Task 3: Create User Profiles

  • Description: This task involves creating user profiles from a list of names. Each profile will include an ID, the original name, and a modified name. The ID is a sequential number starting from 1. The modification of names is done using helper functions processArray and formatArrayStrings imported from the arrayManipulation module.
  • File(s): This task is implemented in a file named userProfileCreation.js.
  • Usage: The createUserProfiles function can be used to generate an array of user profile objects from an array of names. Below are the instructions on how to use the implementation.

Usage

Example const names = ["Alice", "Bob", "Charlie"]; const profiles = createUserProfiles(names); console.log(profiles);

Link to repository [https://github.com/frankmawuli/js-for-react-native-11232324.git].

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published