God-Grace 1.0.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,2 @@
1
+ # __init__.py file ke andar
2
+ from .ganit import addends,minuend,product,divide,traversing,friends_phone,friends_salary,num_to_words,count_frequency,largest_number,smallest_number,check_perfect,check_armstrong,check_palindrome,check_prime,fibonacci_series,valid_age,factorial,reverse_counting,sum_integer,simple_intrest,cube,cube_sum,squa,squa_sum,table,count_odd_even,leap_year,alphabet
@@ -0,0 +1,373 @@
1
+ def addends(*args):
2
+ string_hai = False
3
+ for x in args:
4
+ if type(x) == str:
5
+ string_hai = True
6
+ break
7
+
8
+ if string_hai == True:
9
+ sara_text = ""
10
+ for x in args:
11
+ sara_text = sara_text + str(x)
12
+ return sara_text
13
+ else:
14
+ kul_jod = 0
15
+ for x in args:
16
+ kul_jod = kul_jod + x
17
+ return kul_jod
18
+
19
+ def minuend(*args):
20
+ result = args[0]
21
+ for x in args[1:]:
22
+ result = result - x
23
+ return result
24
+
25
+ def product(*args):
26
+ string_data = None
27
+ number_data = 1
28
+
29
+ for x in args:
30
+ if type(x) == str:
31
+ string_data = x
32
+ else:
33
+ number_data = number_data * x
34
+
35
+ if string_data != None:
36
+ return string_data * number_data
37
+ else:
38
+ return number_data
39
+
40
+ def divide(*args):
41
+ for x in args:
42
+ if type(x) == str:
43
+ return "Error: Strings divide nahi hoti!"
44
+
45
+ result = args[0]
46
+ for x in args[1:]:
47
+ if x == 0:
48
+ return "Error: 0 se bhag nahi de sakte!"
49
+ result = result / x
50
+ return result
51
+
52
+ def traversing(*args):
53
+ for data in args:
54
+ print(f"\nTraversing data type: {type(data)}")
55
+ if type(data) == dict:
56
+ for key in data:
57
+ print(f"Key: {key}, Value: {data[key]}")
58
+ else:
59
+ for item in data:
60
+ print(item)
61
+ return "Program Executed"
62
+
63
+ def friends_phone():
64
+ friends_tupp = ()
65
+ friends_dict = {}
66
+ friends_list = []
67
+ n = int(input("Enter a number of friends you want to add:- "))
68
+ for i in range(n):
69
+ name = input(f"Enter friend {i+1} name:- ")
70
+ phone = int(input("Enter phone number:- "))
71
+ friends_dict[name] = phone
72
+ friends_list.append(name)
73
+ friends_list.append(phone)
74
+ print("\nSelect Options: \n () for Tuple \n [] for List \n {} for Dictionary \n (),[], {} for List, or all together")
75
+ choice = input("Enter the format you want to see: ").strip()
76
+ if "()" in choice and "[]" in choice and "{}" in choice:
77
+ print("Tuple:", tuple(friends_list))
78
+ print("List:", friends_list)
79
+ print("Dictionary:", friends_dict)
80
+ elif "{}" in choice:
81
+ print("Dictionary:", friends_dict)
82
+ elif "[]" in choice:
83
+ print("List:", friends_list)
84
+ elif "()" in choice:
85
+ print("Tuple:", tuple(friends_list))
86
+ else:
87
+ print("Invalid choice! Showing everything by default:")
88
+ print(friends_dict)
89
+ print(friends_list)
90
+ return "Program Executed"
91
+
92
+ def friends_salary():
93
+ friends_tupp = ()
94
+ friends_dict = {}
95
+ friends_list = []
96
+ n = int(input("Enter a number of friends you want to add:- "))
97
+ for i in range(n):
98
+ name = input(f"Enter friend {i+1} name:- ")
99
+ sallery = int(input("Enter sallery:- "))
100
+ friends_dict[name] = sallery
101
+ friends_list.append(name)
102
+ friends_list.append(sallery)
103
+ print("\nSelect Options: \n () for Tuple \n [] for List \n {} for Dictionary \n (),[], {} for List, or all together")
104
+ choice = input("Enter the format you want to see: ").strip()
105
+ if "()" in choice and "[]" in choice and "{}" in choice:
106
+ print("Tuple:", tuple(friends_list))
107
+ print("List:", friends_list)
108
+ print("Dictionary:", friends_dict)
109
+ elif "{}" in choice:
110
+ print("Dictionary:", friends_dict)
111
+ elif "[]" in choice:
112
+ print("List:", friends_list)
113
+ elif "()" in choice:
114
+ print("Tuple:", tuple(friends_list))
115
+ else:
116
+ print("Invalid choice! Showing everything by default:")
117
+ print(friends_dict)
118
+ print(friends_list)
119
+ return "Program Executed"
120
+
121
+ def num_to_words():
122
+ words_map = {'0':'Zero','1':'One','2':'Two','3':'Three',
123
+ '4':'Four','5':'Five','6':'Six','7':'Seven',
124
+ '8':'Eight','9':'Nine'}
125
+ n=int(input("Enter a Number:- "))
126
+ num_str=str(n)
127
+ result=""
128
+ for digit in num_str:
129
+ result+=words_map[digit]+" "
130
+ print(result)
131
+ return "Program Executed"
132
+
133
+ def count_frequency():
134
+ string=input("Enter a String:- ")
135
+ char = input("Enter character to count:- ")
136
+ count = 0
137
+ for chars in string:
138
+ if chars == char:
139
+ count+=1
140
+ print(f"{count} times")
141
+ return "Program Executed"
142
+
143
+ def largest_number():
144
+ n = int(input("Enter how many numbers to compare: "))
145
+ max_no = float('-inf')
146
+ count = 0
147
+ for i in range(n):
148
+ a = int(input(f"Enter Number {i+1}: "))
149
+ if a > max_no:
150
+ max_no = a
151
+ count = 1
152
+ elif a == max_no:
153
+ count += 1
154
+ print("---")
155
+ print(f"The final Largest Number is: {max_no}")
156
+ if count > 1:
157
+ print(f"Note: This number was entered {count} times.")
158
+ return "Program Executed"
159
+
160
+ def smallest_number():
161
+ n = int(input("Enter how many numbers to compare: "))
162
+ min_no = float('inf')
163
+ count = 0
164
+ for i in range(n):
165
+ a = int(input(f"Enter Number {i+1}: "))
166
+ if a < min_no:
167
+ min_no = a
168
+ count = 1
169
+ elif a == min_no:
170
+ count += 1
171
+ print("---")
172
+ print(f"The final Smallest Number is: {min_no}")
173
+ if count > 1:
174
+ print(f"Note: This number appeared {count} times.")
175
+ return "Program Executed"
176
+
177
+ def check_perfect():
178
+ num = int(input("Enter Number You Want To Check:- "))
179
+ Sum = 0
180
+ for i in range(1, num):
181
+ if num % i == 0:
182
+ Sum += i
183
+ if Sum == num:
184
+ print(num, "is a Perfect Number")
185
+ else:
186
+ print(num, "is not a Perfect Number")
187
+ return "Program Executed"
188
+
189
+ def check_armstrong():
190
+ num=int(input("Enter Number You Want To Check:- "))
191
+ Sum=0
192
+ ph=num
193
+ while ph>0:
194
+ digit = ph%10
195
+ Sum+=digit**3
196
+ ph//=10
197
+ if num==Sum:
198
+ print(num, "is a Armstrong Number")
199
+ else:
200
+ print(num, "is not a Armstrong Number")
201
+ return "Program Executed"
202
+
203
+ def check_palindrome():
204
+ a=eval(input("Enter a Name or Number:- "))
205
+ if a==a[::-1]:
206
+ print("Yes, It's Palindrome")
207
+ else:
208
+ print("Ohh, It's not Palindrome")
209
+ return "Program Executed"
210
+
211
+ def check_prime():
212
+ num = int(input("Enter a Number:- "))
213
+ if num < 2:
214
+ print(num, "is not a Prime Number")
215
+ return
216
+ a = int(num / 2) + 1
217
+ for i in range(2, a):
218
+ r = num % i
219
+ if r == 0:
220
+ print(num, "is not a Prime Number")
221
+ break
222
+ else:
223
+ print(num, "is a Prime Number")
224
+
225
+ def fibonacci_series():
226
+ t=int(input("Enter Number:- "))
227
+ f=0
228
+ s=1
229
+ print(f,',',s,end=",")
230
+ for i in range(2,t):
231
+ n=f+s
232
+ print(n,end=",")
233
+ f=s
234
+ s=n
235
+ print("\n")
236
+ return "Program Executed"
237
+
238
+ def valid_age():
239
+ age = int(input("Enter Your Age:- "))
240
+ if age>=18:
241
+ print("yes, this age is valid for voting")
242
+ else:
243
+ print("No,this age is not valid for voting")
244
+ return "Program Executed"
245
+
246
+ def factorial():
247
+ num=int(input("Enter Number"))
248
+ fact=1
249
+ x=1
250
+ while x<=num:
251
+ fact=fact*x
252
+ x+=1
253
+ print("Factorial of",num,"is",fact)
254
+ return "Program Executed"
255
+
256
+ def reverse_counting():
257
+ n=int(input("Enter Number to Count Reverse:- "))
258
+ for i in range(n,0,-1):
259
+ print(i)
260
+ return "Program Executed"
261
+
262
+ def sum_integer():
263
+ print("Its return the sum from given number to 0, either number is + or -")
264
+ n = int(input("Enter Last No to get sum:- "))
265
+ su = 0
266
+ if n >= 1:
267
+ for i in range(1, n + 1):
268
+ su += i
269
+ elif n <= -1:
270
+ for i in range(n, 1):
271
+ su += i
272
+ else:
273
+ su = 0
274
+ print("Total Sum is:", su)
275
+ return "Program Executed"
276
+
277
+ def simple_intrest():
278
+ P=int(input("Enter value of Principle:- "))
279
+ R=int(input("Enter value of Rate:- "))
280
+ T=int(input("Enter value of Time:- "))
281
+ SI=(P*R*T)/100
282
+ print("Simple Intrest is:- ",SI)
283
+ return "Program Executed"
284
+
285
+ def cube(*numbers):
286
+ cubes = [num ** 3 for num in numbers]
287
+ for i, val in enumerate(numbers):
288
+ print(f"Cube of {val} is {cubes[i]}")
289
+ return "Program Executed"
290
+
291
+ def cube_sum(*args):
292
+ return sum(x**3 for x in args)
293
+ return "Program Executed"
294
+
295
+ def squa(*numbers):
296
+ cubes = [num ** 2 for num in numbers]
297
+ for i, val in enumerate(numbers):
298
+ print(f"Cube of {val} is {cubes[i]}")
299
+ return "Program Executed"
300
+
301
+ def squa_sum(*args):
302
+ return sum(x**2 for x in args)
303
+ return "Program Executed"
304
+
305
+ def table():
306
+ n = int(input("Kahan tak table print karni hai? "))
307
+ for i in range(1, n + 1):
308
+ print(f"\n\nTable of {i}:")
309
+ for j in range(1, 11):
310
+ print(f"{i*j}", end=",")
311
+ print()
312
+ return "Program Executed"
313
+
314
+ def count_odd_even():
315
+ n = int(input("Enter a no for range:- "))
316
+ ec = 0
317
+ oc = 0
318
+ for num in range(1, n + 1):
319
+ if num % 2 == 0:
320
+ ec += 1
321
+ else:
322
+ oc += 1
323
+ print("Total Even-Numbers in given range:", ec)
324
+ print("Total Odd-Numbers in given range:", oc)
325
+ return "Program Executed"
326
+
327
+ def check_leap_year(year):
328
+ # Ye sirf logic check karega
329
+ if (year % 4 == 0 and year % 100 != 0) or (year % 400 == 0):
330
+ return True
331
+ else:
332
+ return False
333
+
334
+ def leap_year():
335
+ saal = int(input("Enter a year to check: "))
336
+
337
+ if check_leap_year(saal):
338
+ print(f"{saal} is a Leap Year!")
339
+ else:
340
+ print(f"{saal} is not a Leap Year.")
341
+ return "Program Executed"
342
+
343
+ def analyze_string(text):
344
+ vowels = "aeiouAEIOU"
345
+ v = 0 # Vowels count
346
+ c = 0 # Consonants count
347
+ u = 0 # Uppercase count
348
+ l = 0 # Lowercase count
349
+ d = 0 # Digits count
350
+ for char in text:
351
+ if char.isupper():
352
+ u += 1
353
+ elif char.islower():
354
+ l += 1
355
+ if char.isdigit():
356
+ d += 1
357
+ if char.isalpha():
358
+ if char in vowels:
359
+ v += 1
360
+ else:
361
+ c += 1
362
+ print(f"Results for: '{text}'")
363
+ print(f"Vowels: {v}")
364
+ print(f"Consonants: {c}")
365
+ print(f"Uppercase: {u}")
366
+ print(f"Lowercase: {l}")
367
+ print(f"Digits: {d}")
368
+ def alphabet():
369
+ user_input = input("Enter your string: ")
370
+ analyze_string(user_input)
371
+ return "Program Executed"
372
+
373
+
@@ -0,0 +1,96 @@
1
+ Metadata-Version: 2.1
2
+ Name: God-Grace
3
+ Version: 1.0.1
4
+ Summary: This library has been created for school CS students so that they can do their assignments easily.
5
+ Author: PHarsh
6
+ Classifier: Programming Language :: Python :: 3
7
+ Classifier: License :: OSI Approved :: MIT License
8
+ Classifier: Operating System :: OS Independent
9
+ Requires-Python: >=3.6
10
+ Description-Content-Type: text/markdown
11
+ License-File: LICENSE.txt
12
+
13
+ # 🛠️ God-Grace: Python Multi-Utility Toolkit
14
+
15
+ **God-Grace** ek comprehensive collection hai Python utility functions ki jo arithmetic, mathematical logic, string analysis, aur data management ko asaan banati hai. Ye toolkit multiple data types ko handle karne aur user-provided data ke detailed insights dene ke liye design kiya gaya hai.
16
+
17
+ ---
18
+
19
+ ## 🚀 Features & Usage Examples
20
+
21
+ ### 1. Arithmetic & Power Operations
22
+ Ye functions `*args` ka use karte hain taaki aap ek saath kai saare inputs handle kar sakein.
23
+
24
+ | Function | Description | Example Usage | Result |
25
+ | :--- | :--- | :--- | :--- |
26
+ | `addends()` | Numbers ko jodta hai ya strings ko join karta hai. | `addends(10, 20)` / `addends("Py", "thon")` | `30` / `"Python"` |
27
+ | `minuend()` | Pehle value se baaki sab ko subtract karta hai. | `minuend(100, 10, 5)` | `85` |
28
+ | `product()` | Multiply karta hai ya strings ko repeat karta hai. | `product(5, 4)` / `product("Go", 3)` | `20` / `"GoGoGo"` |
29
+ | `divide()` | Sequence mein division karta hai (with error handling). | `divide(50, 5)` | `10.0` |
30
+ | `cube()` | Diye gaye numbers ka cube print karta hai. | `cube(2, 3)` | `Cube of 2 is 8...` |
31
+ | `squa()` | Diye gaye numbers ka square print karta hai. | `squa(4, 5)` | `Square of 4 is 16...` |
32
+
33
+ ---
34
+
35
+ ### 2. Mathematical Logic Checks
36
+ Functions jo numbers ki properties aur scientific categories verify karte hain.
37
+
38
+ * **`check_prime()`**: Check karta hai ki number sirf 1 aur khud se divide hota hai ya nahi.
39
+ * **`check_armstrong()`**: Verifies if the sum of digits raised to the power of 3 equals the number.
40
+ * **`check_perfect()`**: Check karta hai agar proper divisors ka sum number ke barabar hai.
41
+ * **`check_palindrome()`**: Verifies if a string/number reads the same backward.
42
+ * **`check_leap_year(year)`**: Logic-based check for leap years.
43
+
44
+ ---
45
+
46
+ ### 3. Sequences & Calculations
47
+ * **`factorial()`**: 1 se lekar `n` tak ke saare integers ka product calculate karta hai.
48
+ * **`fibonacci_series()`**: Fibonacci sequence generate karta hai (e.g., 0, 1, 1, 2, 3).
49
+ * **`simple_intrest()`**: Principle, Rate, aur Time ke basis par interest calculate karta hai.
50
+ * **`sum_integer()`**: `n` se 0 tak ka total sum nikalta hai (supports negative input).
51
+
52
+ ---
53
+
54
+ ### 4. String & Text Analysis
55
+ * **`alphabet()`**: String ka detailed analysis (Vowels, Consonants, Case, Digits).
56
+ * **`count_frequency()`**: String mein kisi specific character ki frequency count karta hai.
57
+ * **`num_to_words()`**: Digits ko English word equivalents mein badalta hai (e.g., `45` → `"Four Five"`).
58
+
59
+ ---
60
+
61
+ ### 5. Data & Comparison Tools
62
+ * **`friends_phone()` / `friends_salary()`**: Data manage karta hai aur use **Tuple**, **List**, ya **Dictionary** format mein display karta hai.
63
+ * **`largest_number()` / `smallest_number()`**: Multiple numbers ko compare karke max/min aur unki frequency batata hai.
64
+ * **`count_odd_even()`**: 1 se `n` tak ki range mein Odd aur Even numbers count karta hai.
65
+ * **`traversing(*args)`**: Kisi bhi collection (List, Dict, Tuple) ko iterate karke elements print karta hai.
66
+
67
+ ---
68
+
69
+ ### 6. Loop-Based Utilities
70
+ * **`table()`**: 1 se lekar number `n` tak multiplication tables generate karta hai.
71
+ * **`reverse_counting()`**: `n` se 1 tak reverse counting print karta hai.
72
+
73
+ ---
74
+
75
+ ## 🛠️ How to Use
76
+
77
+ 1. **Library Import Karein:**
78
+ ```python
79
+ import God-Grace
80
+ ```
81
+ 2. **Function Call Karein:**
82
+ Aap function ko directly call kar sakte hain. Kuch functions input terminal mein mangenge:
83
+ ```python
84
+ # Table generator chalane ke liye:
85
+ God-Grace.table()
86
+
87
+ # Prime number check karne ke liye:
88
+ God-Grace.check_prime()
89
+ ```
90
+ 3. **Terminal Mein Run Karein:**
91
+ ```bash
92
+ pip install God-Grace
93
+ ```
94
+
95
+ ## 📝 License
96
+ This toolkit is open-source and free to use for educational purposes.
@@ -0,0 +1,9 @@
1
+ LICENSE.txt
2
+ README.md
3
+ setup.py
4
+ God-Grace/__init__.py
5
+ God-Grace/ganit.py
6
+ God_Grace.egg-info/PKG-INFO
7
+ God_Grace.egg-info/SOURCES.txt
8
+ God_Grace.egg-info/dependency_links.txt
9
+ God_Grace.egg-info/top_level.txt
@@ -0,0 +1 @@
1
+ God-Grace
@@ -0,0 +1,19 @@
1
+ Copyright (c) 2024 [PHarsh]
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining a copy
4
+ of this software and associated documentation files (the "Software"), to deal
5
+ in the Software without restriction, including without limitation the rights
6
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7
+ copies of the Software, and to permit persons to whom the Software is
8
+ furnished to do so, subject to the following conditions:
9
+
10
+ The above copyright notice and this permission notice shall be included in all
11
+ copies or substantial portions of the Software.
12
+
13
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
19
+ SOFTWARE.
@@ -0,0 +1,96 @@
1
+ Metadata-Version: 2.1
2
+ Name: God-Grace
3
+ Version: 1.0.1
4
+ Summary: This library has been created for school CS students so that they can do their assignments easily.
5
+ Author: PHarsh
6
+ Classifier: Programming Language :: Python :: 3
7
+ Classifier: License :: OSI Approved :: MIT License
8
+ Classifier: Operating System :: OS Independent
9
+ Requires-Python: >=3.6
10
+ Description-Content-Type: text/markdown
11
+ License-File: LICENSE.txt
12
+
13
+ # 🛠️ God-Grace: Python Multi-Utility Toolkit
14
+
15
+ **God-Grace** ek comprehensive collection hai Python utility functions ki jo arithmetic, mathematical logic, string analysis, aur data management ko asaan banati hai. Ye toolkit multiple data types ko handle karne aur user-provided data ke detailed insights dene ke liye design kiya gaya hai.
16
+
17
+ ---
18
+
19
+ ## 🚀 Features & Usage Examples
20
+
21
+ ### 1. Arithmetic & Power Operations
22
+ Ye functions `*args` ka use karte hain taaki aap ek saath kai saare inputs handle kar sakein.
23
+
24
+ | Function | Description | Example Usage | Result |
25
+ | :--- | :--- | :--- | :--- |
26
+ | `addends()` | Numbers ko jodta hai ya strings ko join karta hai. | `addends(10, 20)` / `addends("Py", "thon")` | `30` / `"Python"` |
27
+ | `minuend()` | Pehle value se baaki sab ko subtract karta hai. | `minuend(100, 10, 5)` | `85` |
28
+ | `product()` | Multiply karta hai ya strings ko repeat karta hai. | `product(5, 4)` / `product("Go", 3)` | `20` / `"GoGoGo"` |
29
+ | `divide()` | Sequence mein division karta hai (with error handling). | `divide(50, 5)` | `10.0` |
30
+ | `cube()` | Diye gaye numbers ka cube print karta hai. | `cube(2, 3)` | `Cube of 2 is 8...` |
31
+ | `squa()` | Diye gaye numbers ka square print karta hai. | `squa(4, 5)` | `Square of 4 is 16...` |
32
+
33
+ ---
34
+
35
+ ### 2. Mathematical Logic Checks
36
+ Functions jo numbers ki properties aur scientific categories verify karte hain.
37
+
38
+ * **`check_prime()`**: Check karta hai ki number sirf 1 aur khud se divide hota hai ya nahi.
39
+ * **`check_armstrong()`**: Verifies if the sum of digits raised to the power of 3 equals the number.
40
+ * **`check_perfect()`**: Check karta hai agar proper divisors ka sum number ke barabar hai.
41
+ * **`check_palindrome()`**: Verifies if a string/number reads the same backward.
42
+ * **`check_leap_year(year)`**: Logic-based check for leap years.
43
+
44
+ ---
45
+
46
+ ### 3. Sequences & Calculations
47
+ * **`factorial()`**: 1 se lekar `n` tak ke saare integers ka product calculate karta hai.
48
+ * **`fibonacci_series()`**: Fibonacci sequence generate karta hai (e.g., 0, 1, 1, 2, 3).
49
+ * **`simple_intrest()`**: Principle, Rate, aur Time ke basis par interest calculate karta hai.
50
+ * **`sum_integer()`**: `n` se 0 tak ka total sum nikalta hai (supports negative input).
51
+
52
+ ---
53
+
54
+ ### 4. String & Text Analysis
55
+ * **`alphabet()`**: String ka detailed analysis (Vowels, Consonants, Case, Digits).
56
+ * **`count_frequency()`**: String mein kisi specific character ki frequency count karta hai.
57
+ * **`num_to_words()`**: Digits ko English word equivalents mein badalta hai (e.g., `45` → `"Four Five"`).
58
+
59
+ ---
60
+
61
+ ### 5. Data & Comparison Tools
62
+ * **`friends_phone()` / `friends_salary()`**: Data manage karta hai aur use **Tuple**, **List**, ya **Dictionary** format mein display karta hai.
63
+ * **`largest_number()` / `smallest_number()`**: Multiple numbers ko compare karke max/min aur unki frequency batata hai.
64
+ * **`count_odd_even()`**: 1 se `n` tak ki range mein Odd aur Even numbers count karta hai.
65
+ * **`traversing(*args)`**: Kisi bhi collection (List, Dict, Tuple) ko iterate karke elements print karta hai.
66
+
67
+ ---
68
+
69
+ ### 6. Loop-Based Utilities
70
+ * **`table()`**: 1 se lekar number `n` tak multiplication tables generate karta hai.
71
+ * **`reverse_counting()`**: `n` se 1 tak reverse counting print karta hai.
72
+
73
+ ---
74
+
75
+ ## 🛠️ How to Use
76
+
77
+ 1. **Library Import Karein:**
78
+ ```python
79
+ import God-Grace
80
+ ```
81
+ 2. **Function Call Karein:**
82
+ Aap function ko directly call kar sakte hain. Kuch functions input terminal mein mangenge:
83
+ ```python
84
+ # Table generator chalane ke liye:
85
+ God-Grace.table()
86
+
87
+ # Prime number check karne ke liye:
88
+ God-Grace.check_prime()
89
+ ```
90
+ 3. **Terminal Mein Run Karein:**
91
+ ```bash
92
+ pip install God-Grace
93
+ ```
94
+
95
+ ## 📝 License
96
+ This toolkit is open-source and free to use for educational purposes.
@@ -0,0 +1,84 @@
1
+ # 🛠️ God-Grace: Python Multi-Utility Toolkit
2
+
3
+ **God-Grace** ek comprehensive collection hai Python utility functions ki jo arithmetic, mathematical logic, string analysis, aur data management ko asaan banati hai. Ye toolkit multiple data types ko handle karne aur user-provided data ke detailed insights dene ke liye design kiya gaya hai.
4
+
5
+ ---
6
+
7
+ ## 🚀 Features & Usage Examples
8
+
9
+ ### 1. Arithmetic & Power Operations
10
+ Ye functions `*args` ka use karte hain taaki aap ek saath kai saare inputs handle kar sakein.
11
+
12
+ | Function | Description | Example Usage | Result |
13
+ | :--- | :--- | :--- | :--- |
14
+ | `addends()` | Numbers ko jodta hai ya strings ko join karta hai. | `addends(10, 20)` / `addends("Py", "thon")` | `30` / `"Python"` |
15
+ | `minuend()` | Pehle value se baaki sab ko subtract karta hai. | `minuend(100, 10, 5)` | `85` |
16
+ | `product()` | Multiply karta hai ya strings ko repeat karta hai. | `product(5, 4)` / `product("Go", 3)` | `20` / `"GoGoGo"` |
17
+ | `divide()` | Sequence mein division karta hai (with error handling). | `divide(50, 5)` | `10.0` |
18
+ | `cube()` | Diye gaye numbers ka cube print karta hai. | `cube(2, 3)` | `Cube of 2 is 8...` |
19
+ | `squa()` | Diye gaye numbers ka square print karta hai. | `squa(4, 5)` | `Square of 4 is 16...` |
20
+
21
+ ---
22
+
23
+ ### 2. Mathematical Logic Checks
24
+ Functions jo numbers ki properties aur scientific categories verify karte hain.
25
+
26
+ * **`check_prime()`**: Check karta hai ki number sirf 1 aur khud se divide hota hai ya nahi.
27
+ * **`check_armstrong()`**: Verifies if the sum of digits raised to the power of 3 equals the number.
28
+ * **`check_perfect()`**: Check karta hai agar proper divisors ka sum number ke barabar hai.
29
+ * **`check_palindrome()`**: Verifies if a string/number reads the same backward.
30
+ * **`check_leap_year(year)`**: Logic-based check for leap years.
31
+
32
+ ---
33
+
34
+ ### 3. Sequences & Calculations
35
+ * **`factorial()`**: 1 se lekar `n` tak ke saare integers ka product calculate karta hai.
36
+ * **`fibonacci_series()`**: Fibonacci sequence generate karta hai (e.g., 0, 1, 1, 2, 3).
37
+ * **`simple_intrest()`**: Principle, Rate, aur Time ke basis par interest calculate karta hai.
38
+ * **`sum_integer()`**: `n` se 0 tak ka total sum nikalta hai (supports negative input).
39
+
40
+ ---
41
+
42
+ ### 4. String & Text Analysis
43
+ * **`alphabet()`**: String ka detailed analysis (Vowels, Consonants, Case, Digits).
44
+ * **`count_frequency()`**: String mein kisi specific character ki frequency count karta hai.
45
+ * **`num_to_words()`**: Digits ko English word equivalents mein badalta hai (e.g., `45` → `"Four Five"`).
46
+
47
+ ---
48
+
49
+ ### 5. Data & Comparison Tools
50
+ * **`friends_phone()` / `friends_salary()`**: Data manage karta hai aur use **Tuple**, **List**, ya **Dictionary** format mein display karta hai.
51
+ * **`largest_number()` / `smallest_number()`**: Multiple numbers ko compare karke max/min aur unki frequency batata hai.
52
+ * **`count_odd_even()`**: 1 se `n` tak ki range mein Odd aur Even numbers count karta hai.
53
+ * **`traversing(*args)`**: Kisi bhi collection (List, Dict, Tuple) ko iterate karke elements print karta hai.
54
+
55
+ ---
56
+
57
+ ### 6. Loop-Based Utilities
58
+ * **`table()`**: 1 se lekar number `n` tak multiplication tables generate karta hai.
59
+ * **`reverse_counting()`**: `n` se 1 tak reverse counting print karta hai.
60
+
61
+ ---
62
+
63
+ ## 🛠️ How to Use
64
+
65
+ 1. **Library Import Karein:**
66
+ ```python
67
+ import God-Grace
68
+ ```
69
+ 2. **Function Call Karein:**
70
+ Aap function ko directly call kar sakte hain. Kuch functions input terminal mein mangenge:
71
+ ```python
72
+ # Table generator chalane ke liye:
73
+ God-Grace.table()
74
+
75
+ # Prime number check karne ke liye:
76
+ God-Grace.check_prime()
77
+ ```
78
+ 3. **Terminal Mein Run Karein:**
79
+ ```bash
80
+ pip install God-Grace
81
+ ```
82
+
83
+ ## 📝 License
84
+ This toolkit is open-source and free to use for educational purposes.
@@ -0,0 +1,4 @@
1
+ [egg_info]
2
+ tag_build =
3
+ tag_date = 0
4
+
@@ -0,0 +1,23 @@
1
+ from setuptools import setup, find_packages
2
+ import os
3
+
4
+ # README file ko UTF-8 encoding ke sath read karna zaroori hai
5
+ with open("README.md", "r", encoding="utf-8") as fh:
6
+ long_description = fh.read()
7
+
8
+ setup(
9
+ name="God-Grace", # 'boon' pehle se exist karta hai, isliye ye unique name rakha hai
10
+ version="1.0.1", # Version badal diya hai upload error se bachne ke liye
11
+ author="PHarsh",
12
+ description='''This library has been created for school CS students so that they can do their assignments easily.
13
+ This library is currently under development more functions will be added in the next version.''',
14
+ long_description=long_description,
15
+ long_description_content_type="text/markdown",
16
+ packages=find_packages(),
17
+ classifiers=[
18
+ "Programming Language :: Python :: 3",
19
+ "License :: OSI Approved :: MIT License",
20
+ "Operating System :: OS Independent",
21
+ ],
22
+ python_requires='>=3.6',
23
+ )