Given an integer
n
, return the number of strings of lengthn
that consist only of vowels (a
,e
,i
,o
,u
) and are lexicographically sorted.A string
s
is lexicographically sorted if for all validi, s[i]
is the same as or comes befores[i+1]
in the alphabet.
給予一正整數
n
,回傳所有只包含母音 (a
,e
,i
,o
,u
)、按照字典順序排序的字串數量。一個字串
s
如果是按字典順序排序,表示對於所有有效的i, s[i]
來說,s[i+1]
一定和他相同或是在它之前。
1 <= n <= 50
Example 1:
Example 2:
Example 3:
LeetCode
C++