Skip to content

rugema3/COATASKFORCE

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

COA TASKFORCE TAKE HOME CHALLENGE

Overview

This project is a coding challenge where I evaluate my skills in HTML, CSS, and JavaScript through two main tasks: a UI design challenge and a coding challenge.

Installation

I have installed the following dependencies on my machine:
  • Node.js: Installed using the commands: arduino
    curl -sL https://deb.nodesource.com/setup_14.x | sudo -E bash -
    sudo apt-get install -y nodejs
    

  • Additionally, I made my JavaScript files executable using the command:
    chmod +x *.js
    

  • With these installations completed, I'm ready to work on the project.

    Tasks Completed

    UI Challenge: Interactive Photo Gallery

  • Built a responsive photo gallery based on provided Figma designs.
  • Ensured accurate representation across devices and browsers.
  • Coding Challenge:

  • Solved two JavaScript coding challenges:
    1. Coding Challenge 1: Array Manipulation:

      Given an array of integers and a target sum, determine if there exists a contiguous subarray within the array that sums up to the target. Return true if such a subarray exists, otherwise return false.

      Example:
      input: arr = [4, 2, 7, 1, 9, 5], target = 17
      Output: true
      Explanation: The subarray [7, 1, 9] sums up to 17, which is equal to the target.
    2. Coding Challenge 2: String Transformation: Given a string, transform it based on the following rules:
      • If the length of the string is divisible by 3, reverse the entire string.
      • If the length of the string is divisible by 5, replace each character with its ASCII code.
      • If the length of the string is divisible by both 3 and 5 (i.e., divisible by 15), perform both operations in the order specified above.
      • Example: Input: "Hamburger"
        Output: "regrubmaH"
        Explanation: The length of the string is 9, which is divisible by 3 but not by 5 or 15. Therefore, the string is reversed, resulting in "regrubmaH".
        Example: Input: "Pizza"
        Output: "80 105 122 122 97"
        Explanation: The length of the string is 5, which is divisible by 5 but not by 3 or 15. Therefore, each character is replaced by its ASCII code, resulting in "80 105 122 122 97".
        Example: Input: "Chocolate Chip Cookie"
        Output: "eikooCpihCetalocohC"
        Explanation: The length of the string is 21, which is divisible by 3 but not by 5 or 15. Therefore, the string is reversed, resulting in "eikooCpihCetalocohC".
  • About

    No description, website, or topics provided.

    Resources

    Stars

    Watchers

    Forks

    Releases

    No releases published

    Packages

    No packages published