Welcome to Silicon Valley! For this assignment, our domain is the startup world! We have three models - Startup
, VentureCapitalist
, and FundingRound
. A Startup
has many VentureCapitalist
s through FundingRound
s.
If you are not sketching out your domain, and thinking about single source of truth, you are doing it wrong :(
- Classes vs Instances
- Variable Scope ( Class, Instance, Local )
- Object Relationships
- Arrays and Array Methods
- Class Methods
Your goal is to build out all of the methods listed in the deliverables. Do your best to follow Ruby best practices. For example, use higher-level array methods such as map
, select
, and find
when appropriate in place of each
We've provided you with a console that you can use to test your code. To enter a console session, run ruby tools/console.rb
from the command line. You'll be able to test out the methods that you write here. Take a look at that file to see how you can pre-define variables and create object instances, rather than manually doing it in every single console session.
Remember! This is a code challenge without tests. You cannot run rspec
you cannot run learn
. You'll need to create your own sample instances for testing purposes. Make sure your associations and methods work in the console before submitting.
VentureCapitalist#invested
- given a domain string, returns the total amount invested in that domain