This site is to serve as my note-book and to effectively communicate with my students and collaborators. Every now and then, a blog may be of interest to other researchers or teachers. Views in this blog are my own. All rights of research results and findings on this blog are reserved. See also http://youtube.com/c/hongqin
@hongqin
Friday, July 1, 2016
scramble words in R for word puzzles
Use the following codes to solve some word puzzles
x = "petormcu" #computer
x = unlist(strsplit(x, split=''))
str(x)
for( i in 1:15){
print( paste(sample(x), collapse = '') )
}
#todo: can check match with words from a database.
No comments:
Post a Comment