Thundrcraft

Thundrcraft Just Code

“Craftr.co.zw  is a powered content creation for businesses. Generate high‑quality copy, posts, and marketing assets qui...
02/12/2025

“Craftr.co.zw is a powered content creation for businesses. Generate high‑quality copy, posts, and marketing assets quickly and consistently. Boost productivity and engage your audience with data‑driven content.



https://craftr.co.zw/

Click the link above and start now👍👍😁

30/03/2019

import json
from difflib import get_close_matches as gcm

data = json.load(open("demo.json"))

def transalate(w):
s = w.lower()
num=gcm(s,data.keys())
if s in data:
return data[s]

elif len(num) > 0:
m = num[0]
ans = input("Suggestion %s found enter 1 to find word and 2 to exit: " % m)
if ans.upper() == "1":
return data[m]
elif ans == "2":
return "The word doesnt not found in our dictionary."
else:
return "Entry not found"

else:
return "Word doesnt exist in our dictionary please double check it and try again."
word = input("Enter word to find: ")
output = transalate(word)
if type(output)==list:
c=0
for item in output:
c=c+1
print('{0}. {1}'.format(c, item))
else:
c=c+1
print('{0}. {1}'.format(c, output))

30/03/2019

the sample json demo json
{
"lining": ["Something put around something else, usually in order to give it another look or to protect it from its environment."],
"rain": ["Precipitation in the form of liquid water drops with diameters greater than 0.5 millimetres.", "To fall from the clouds in drops of water."],
"auscultation": ["Listening to the heart and lungs using a stethoscope."]
}

30/03/2019

Python simple search and loading

D-The Dependency Inversion Principle (DIP) encourages you to write code that depends upon abstractions rather than upon ...
10/02/2018

D-The Dependency Inversion Principle (DIP) encourages you to write code that depends upon abstractions rather than upon concrete details. You can recognize this in the code you read by looking for a class or method that takes something generic like "Stream" and performs operations on it, as opposed to instantiating a specific Filestream or Stringstream or whatever. This gives the code in question a lot more flexibility -- you can swap in anything that conforms to the Stream abstraction and it will still work.

To visualize this in your day to day, go down to your local store and pay for something with a credit card. The clerk doesn't examine your card and get out the "Visa Machine" after seeing that your card is a Visa. He just takes your card, whatever it is, and swipes it. Both you and the clerk depend on the credit card abstraction without worrying about specifics.

follow=>

Demonstrating the SOLID design principles in Java

I- The Interface Segregation Principle (ISP) says that you should favor many, smaller, client-specific interfaces over o...
10/02/2018

I- The Interface Segregation Principle (ISP) says that you should favor many, smaller, client-specific interfaces over one larger, more monolithic interface. In short, you don't want to force clients to depend on things they don't actually need. Imagine your code consuming some big, fat interface and having to re-compile/deploy with annoying frequency because some method you don't even care about got a new signature.

To picture this in the real world, think of going down to your local corner restaurant and checking out the menu. You'll see all of the normal menu mainstays, and then something that's just called "soup of the day." Why do they do this? Because the soup changes a lot and there's no sense reprinting the menus every day. Clients that don't care about the soup needn't even be concerned, and clients that do use a different interface -- asking the server.
example =>

Demonstrating the SOLID design principles in Java

Address

Harare
480

Alerts

Be the first to know and let us send you an email when Thundrcraft posts news and promotions. Your email address will not be used for any other purpose, and you can unsubscribe at any time.

Contact The Business

Send a message to Thundrcraft:

Share