7 kyu
Tea for two
2,833 of 2,834ransy
Description:
Tea for two!
Given a string or number write a function tea42 that takes as input a string or number and returns a string where every '2' charcter or digit has been replaced with a t.
tea42('coffee') //should return 'coffee'
tea42('tea') //should return 'tea'
tea42('2ea') //should return 'tea'
tea42(9022) //should return '90tt'
tea42(5676765) //should return '5676765'
tea42('2u2u') //should return 'tutu'
Fundamentals
Strings
Similar Kata:
Stats:
Created | May 19, 2015 |
Published | May 19, 2015 |
Warriors Trained | 4078 |
Total Skips | 253 |
Total Code Submissions | 7736 |
Total Times Completed | 2834 |
JavaScript Completions | 2833 |
CoffeeScript Completions | 11 |
Total Stars | 27 |
% of votes with a positive feedback rating | 92% of 373 |
Total "Very Satisfied" Votes | 320 |
Total "Somewhat Satisfied" Votes | 44 |
Total "Not Satisfied" Votes | 9 |