Request edit access
Developer in Httplab
Application form
Sign in to Google to save your progress. Learn more
Your Name *
Your Email *
Date of Birth *
City, Country of residence. Citizenship.  *
What is your working environment? OS, code editor, tools. *
Tell us about your education, work experience, projects that you were involved in. *
Github, any links to repos, PRs, gists, etc.
Phone number / Telegram account / ...
Skills
Please rate your experience and skills with the listed technologies on a ten-point scale.
Ruby *
Ruby on Rails *
JavaScript *
CSS *
SQL *
Unix Shell, Command Line Tools *
Few tasks
We've came up with few complex (and not so) tasks to reveal your skills. Attach an answer to each of them in the form below. Hopefully they will bring you as much pleasure as they bring us.
(Language — Ruby on Rails)
1/7. Write code that prints the value of the postcode attribute of the addresses of 100 users in the database.
class User < ApplicationRecord
  has_one :address
end

class Address < ApplicationRecord
  belongs_to :user
end
*
2/7. Is this code equivalent?
v1 = true and false
v2 = true && false
*
3/7. Hash
What can you use as keys for Hash data structure in ruby?

*
4/7. Membership
User is linked with organization through members table. Does this method look good?

def invite_user_to_organization(organization, user_params)
  user = User.create(user_params)

  if user.persisted?
    organization.members.create(user_id: user.id)
    UserMailer.notify_about_new_membership(user)
  end

  user
end

*
5/7. Emails
Let's imagine you're working on mailing list service and you are writing code which should send newsletter to all emails except unsubscribed. Does this implementation look good?
mailing_list = ['john@foo', 'alice@bar', ...]
unsubscribed_emails = ['alice@buz', ...]

unsubscribed_emails.each { |email| mailing_list.delete(email) }

send_newsletter(mailing_list)

*
6/7. Unique tokens
We don't want to expose real IDs of ActiveRecord models in public so we want to add column "token" to each model and invent solution to generate unique tokens randomly. Please write short implementation which can illustrate your possible solution.

*
7/7. Scheduling service
Let's imagine that you need to create service which allows user to set timestamp and message to be notified by email or sms in the given moment of time in future. How would you implement it?
*
Thank you!
Submit
Clear form
Never submit passwords through Google Forms.
This form was created inside of HttpLab.

Does this form look suspicious? Report