OCTO电话面试悲剧

Behavior Questions:

whom is your favorite programer? why?

why you use Python? why not others?

could you describe your project now? why you don't use some other open source tools? how is the server structure? how you do connections between different servers?

may i know how do you design database? schema?

did your app support parallel running? do you use concurrency in Python? 

 

Coding Question:

 

Write a function which takes in a string as an argument and returns a dictionary with the following three key, value pairs:

“num_letters”, number of letters in the string

“num_digits”, number of digits in the string

“num_neither”, number of characters that are neither letters nor digits in the string

First Solution:

def calcStr(str_):

    num_letters, num_digits, num_neither = 0, 0, 0

    result_ = { ‘num_letters’:0, ‘num_digits’: 0, ‘num_neither’: 0}

    for char_ in str_:

        if is_digit(char_):

            num_digits += 1

        elif is_str(char_):

            num_letters += 1

        else:

            num_neither += 1

    result_[‘num_digits’]=num_digits

    result_[‘num_letters’]=num_letters

    result_[‘num_neither’]=num_neither

    return result_

Followed questions:

Can you do it without for loop?

Do you know comprehension?

Can you do it with some python way?

Can you do it with map?

Do you have any questions?

I should ask more technical queries about work and what they expect the position people to do.

1. what do you expect from the candidate? why you need a new hand?

2. may i know if python and angular.js will be the main technology for this position?

你可能感兴趣的:(面试)