Im stuck on this level can you help?

3. is_int

Thanks in Advance!!!


Here's my code D:

def is_int(x):
    if x is int:
        return True
        return False

Here is the link as well :smiley:


Oh ya, I rely on the forum to MUCH


This question already exists. check out this link for some hints:


But It doesn't matter if it exists its the Q & A forum so you can create your OWN questions... I'm not just gonna look for answers elsewhere.


I used that topic and couldn't figure anything out. What was said in that topic was to complicated and I didn't understand it enough.


Help me please :smiley: ...


Nevermind you were not helpful :anger: :anger: :anger:
I figured it out. hope you're happy now! :rage:


I agree. The too cool for school attitude is unhelpful. A box of parts does not insure a mechanic talks to you. Teaching professionalism 101 is as important for the participants to demonstrate as the moderators. I came up with his answer but thought I must be nuts. If those who can't do teach, I find the converse is regrettably also true. There's a difference between off roading and disaster flick AND the difference might not be the attitude of the lead. Be kind professionalism is also kinda like always getting just jello molds at your potluck: grand total $2. Confused affronted and disappointed and 'I've known this person how long?'. The EQs have as much right to criticism as the IQs. Please stop and think. Keep trying. Coding is I'm finding as much about understanding why a guy who eats junk food suddenly cares about the price of carrots. Don't let the psychology defeat you.


Don't forget to include absolute value.


Thanks for the support it really got me out of my rage. :smiley:


The guy (jgiglio) is helping other people... weird


Not shut yet... :slight_smile:


hello everyone,
(floats in python are actually doubles) can also be an integer (if it has nothing after the decimal point). I use the built-in is_integer() method on doubles to check this.

def is_int(x):

if float(x).is_integer():
    return True
    return False

print is_int(-3.4)


That code doesn't work


Do you need help with it?


its working for me...!