Q1. Assume that the following code must have the stated execution result.
__(1)__
x.each_line { |line| puts line }
[Execution Result]
apple
#!/usr/bin/env ruby | |
require 'mail' | |
mysql_username = 'root' | |
mysql_password = '123456' | |
mysql_database = 'test' | |
system("mysqldump --user=#{mysql_username} --password=#{mysql_password} --single-transaction #{mysql_database} > backup.sql") | |
# Credit to : |
<iframe id="_if3" scrolling="no" style="width : 100%" ></iframe> | |
<script> | |
(function() { | |
var oIf = document.getElementById('_if3'), | |
win = oIf.contentWindow, | |
doc = oIf.contentWindow.document; | |
doc.write('<html><head></head><body><script> google_ad_client = "pub-1821434700708607"; google_ad_slot = "8156194155"; google_ad_width = 200; google_ad_height = 200; </sc' + 'ript><script src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></sc' + 'ript>'); | |
if(doc.all) { |
# capistrano deployment | |
require "bundler/capistrano" | |
require "capistrano/ext/multistage" | |
set :stages, %w(canary production) | |
set :default_stage, "canary" | |
set :application, "lolcats" | |
set :deploy_to, "/srv/#{application}" |
require 'bundler/capistrano' | |
set :application, "net" | |
set :repository, "git@githost.com:net.git" | |
set :scm, :git | |
set :default_environment, { | |
'PATH' => "$HOME/.rbenv/shims:$HOME/.rbenv/bin:$PATH" | |
} |
require 'rake' | |
require 'rake/testtask' | |
Rake::TestTask.new do |t| | |
t.test_files = Dir.glob('spec/**/*_spec.rb') | |
end | |
task(default: :test) |