Skip to content

Commit 4d63ffd

Browse files
authored
Update README.md example
1 parent 08ebd0b commit 4d63ffd

1 file changed

Lines changed: 10 additions & 12 deletions

File tree

README.md

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -95,20 +95,18 @@ This way you have all the documentation and source code to understand our projec
9595
### Example
9696

9797
```python
98-
from openhosta import *
98+
from OpenHosta import emulate, config
9999
100-
config.set_default_apiKey("example-apikey")
100+
config.set_default_apiKey("put-your-api-key-here")
101101
102-
def my_func(a:int, b:str)->dict:
103-
"""
104-
This Function does something.
105-
"""
106-
return emulate()
102+
def translate(text:str, language:str)->str:
103+
"""
104+
This function translates the text in the “text” parameter into the language specified in the “language” parameter.
105+
"""
106+
return emulate()
107107
108-
my_func(5, "Hello World!")
109-
110-
my_lambda = thought("Do something")
111-
my_lambda(5)
108+
result = translate("Hello World!", "French")
109+
print(result)
112110
```
113111
You check OpenHosta's [documentation](doc/Docs.md) for more detailled informations or exemple
114112
@@ -146,4 +144,4 @@ GitHub: https://github.com/hand-e-fr/OpenHosta
146144
147145
Thank you for your interest in our project and your potential contributions!
148146
149-
**The OpenHosta Team**
147+
**The OpenHosta Team**

0 commit comments

Comments
 (0)