Skip to content

Instantly share code, notes, and snippets.

View RashneetR's full-sized avatar

Rashneet Kaur Rajpal RashneetR

View GitHub Profile
@RashneetR
RashneetR / create_repo.rb
Created December 10, 2020 06:06
create a new github repository
# Create a new repository on the command line
touch README.md
git init
git add README.md
git commit -m "first commit"
git remote add origin https://github.com/RashneetR/project_name.git
git push -u origin master
# Push an existing repository from the command line
@RashneetR
RashneetR / garbage.rb
Created December 8, 2020 05:50
Garbage collection Example with Ruby Version
# This script shows how garbage collection is done for symbols Ruby 2.2.1 onwards
# Ruby 2.1
100_000.times do |i|
"sym_#{i}".to_sym
end
# => 100000