Hide keyboard shortcuts

Hot-keys on this page

r m x p   toggle line displays

j k   next/prev highlighted chunk

0   (zero) top of page

1   (one) first highlighted chunk

1from random import randint 

2 

3 

4class Patrimony: 

5 

6 def __init__(self, id, type_of_strategy=None, *args, **kwargs): 

7 self.id = id 

8 self.type_of_strategy = type_of_strategy 

9 self.rental_price = randint(30, 120) 

10 self.property_price = randint(30, 120) 

11 

12 def __repr__(self): 

13 return f''' 

14 id:{self.id} 

15 type_of_strategy:{self.type_of_strategy} 

16 rental_price:{self.rental_price} 

17 property_price:{self.property_price} 

18 ''' 

19 

20 def __str__(self): 

21 return f''' 

22 id:{self.id} 

23 type_of_strategy:{self.type_of_strategy} 

24 rental_price:{self.rental_price} 

25 property_price:{self.property_price} 

26 '''