Code Monkey home page Code Monkey logo

book3-campaign's Introduction

Challenge: Political Campaign

Challenges are optional exercises that you should attempt only if you've completed the practice exercises and understand the concepts.

You have volunteered your time to a local political candidate, Elizabeth Sanger, who wants to become a US representative in Congress for your district. Unfortunately, the team discovered that you're a software developer, so they have begged you to build an application that lets them track volunteers, and store information about Elizabeth and her campaign.

Your job is to define the different objects and arrays, their structure, and the corresponding properties for each, to represent the following information about Elizabeth's campaign.

  1. Her congressional district (you can use yours here)
  2. Her platform statements for the following issues.
    1. Taxes
    2. Jobs
    3. Infrastructure
    4. Health care
    5. Crime and enforcement
  3. URL for donation form
  4. Calendar of events
  5. Volunteer information
    1. Name
    2. Address
    3. Email
    4. Phone number
    5. Availability
    6. What activities each one is willing to do (e.g. answering phone calls, taking polls, etc.)
  6. Biography
  7. Image gallery
    1. Head shot
    2. Picture of family
    3. Picture of constituents
  8. Mission statement
  9. URL for registering to vote

Advanced Challenge

Advanced challanges are intended to be difficult and the expectation is for you to use your imagination, and research skills to make your own decisions about which code should be written.

After you have defined all the objects for representing the data about Elizabeth's campaign, write a corresponding function for each one whose purpose is to change the state of the object. Then use your functions to modify the existing data.

Things to think about.

  • Am I modifying an array? Then the function argument should be added to the target array with the push() method.
  • Am I modifying an object? Then I should pass both the key name to be modified, and its corresponding value.

This challenge is for you to practice writing functions, so the more you can write, the better. It helps make neural connections in your brain at this point since you're still building your software vocabulary.

Example:

function addToImageGallery (newImage) {
    ...
}

function changeBiography (newBiography) {
    ...
}

function changePlatform (topic, newPlatformStatement) {
    ...
}

book3-campaign's People

Contributors

scivarolo avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.