What does O(log n) mean exactly?

I cannot understand how to identify a function with a log time. The most common attributes of logarithmic running-time function are that: the choice of the next element on which to perform some action is one of several possibilities, and only one will need to be chosen. or the elements on which the action is … Read more

What does %>% function mean in R?

%…% operators %>% has no builtin meaning but the user (or a package) is free to define operators of the form %whatever% in any way they like. For example, this function will return a string consisting of its left argument followed by a comma and space and then it’s right argument. The base of R … Read more

Categories R

“inconsistent use of tabs and spaces in indentation”

I’m trying to create an application in Python 3.2 and I use tabs all the time for indentation, but even the editor changes some of them into spaces and then print out “inconsistent use of tabs and spaces in indentation” when I try to run the program. How can I change the spaces into tabs? … Read more

Program to Unjumble Words on Python [closed]

To accomplish this, you will need a database of viable words. An english dictionary will do. One way is to check for words in the database that are anagrams of the jumbled string. Here’s a naive algo: read the viable words into an appropriate data structure a python dict or tuple will suffice. Assume the … Read more