Simple random number generator
Code organization

Rather than having your code in the global namespace, it's better to wrap it into a method, for example:

def gen_random_number():
    randomNumber = random.randint(1, z)
    print "first random", randomNumber
    # ...


And call the method like this:

if __name__ == '__main__':
    gen_random_number()


Magic numbers

Avoid using "magic numbers": the numbers 40, 100, 35, 93 are "magic" because it's unclear what they are and why. If you put them in capitalized constants near the top of the file with a good name, it becomes much clearer what they are and their purpose, for example:

LOWER_BOUND = 40
UPPER_BOUND = 100

z = random.randint(LOWER_BOUND, UPPER_BOUND)


For 40 and 100 it was easy enough to guess what they are and give these names. But for 35, 93 I'm not sure. If you had given them a name, I wouldn't have to wonder.

Formatting

There is an official standard Python style guide called PEP8. I suggest to read and follow that, it will make it easier for others to review your code. There is command line utility called pep8 that can detect coding style violations. You can install it with pip install pep8, and run it on your script (or even an entire directory) simply with pep8 path/to/your/code.

Your code reformatted and variables renamed to follow PEP8 would look like this:

random_number = random.randint(1, z)
print "first random", random_number

if 35 &gt;= random_number:
    new_random = random_number * .5
    new_random += 9
    print "second random " "%.f" % new_random

elif 36 &lt;= random_number &lt;= 93:
    new_random = random_number + 7
    print "second random " "%.f" % new_random

else:
    new_random = random_number
    print "second random", new_random




Although PEP8 doesn't complain about this:


print "second random " "%.f" % new_random



There's no need to put a space between those two strings, so you can write it simply:

print "second random %.f" % new_random




You could further simplify this:


new_random = random_number * .5
new_random += 9



to this:

new_random = random_number * .5 + 9