File tree Expand file tree Collapse file tree 4 files changed +23
-2
lines changed Expand file tree Collapse file tree 4 files changed +23
-2
lines changed Original file line number Diff line number Diff line change 1
- # Implement an algorithm to determine if a string has all unique charactersself.
2
- # What if you cannot use additional data structures.
1
+ """
2
+ Is Unique: Implement an algorithm to determine if a string has all unique
3
+ characters. What if you cannot use additional data structures?
4
+ """
3
5
4
6
5
7
def isUnique (string_ ):
Original file line number Diff line number Diff line change
1
+ """
2
+ Check Permutation: Given two strings,write a method to decide if
3
+ one is a permutation of the other.
4
+ """
5
+
6
+
7
+
8
+
1
9
def perm_check (str_1 ,str_2 ):
2
10
if len (str_1 ) != len (str_2 ):#If both str are diiferent lenghts return false
3
11
return False
Original file line number Diff line number Diff line change
1
+ """
2
+ URLify: Write a method to replace all spaces in a string with '%20'. You may
3
+ assume that the string has sufficient space at the end to hold the additional
4
+ characters,and that you are given the "true" length of the string.
5
+ (Note: If implementing in Java,please use a character array so that you can
6
+ perform this operation in place.)
7
+ EXAMPLE
8
+ Input: "Mr John Smith ", 13 Output: "Mr%20John%20Smith"
9
+ """
10
+
11
+ def urlify (str ):
You can’t perform that action at this time.
0 commit comments