Python | Check the memory usage of  an object >>> import sys >>> x = 100 >>> print(sys.getsizeof(x)) 28  

Last updated 3 months, 2 weeks ago | 118 views

Tags:- Python

Python | Print String N times >>> s = 'Python' >>> n = 5 >>> print(s * n) PythonPythonPythonPythonPython  

Last updated 3 months, 2 weeks ago | 91 views

Tags:- Python Django

Python | Return multiple values from functions >>> def A(): return 2, 3, 4 >>> a, b, c = A() >>> print(a, b, c) 2 3 4  

Last updated 3 months, 2 weeks ago | 87 views

Tags:- Python Django

Python | Join all items of a list to convert into a single string >>> x = ["Python", "Online", "Training"] >>> print(" ".join(x)) Python Online Training  

Last updated 3 months, 2 weeks ago | 72 views

Tags:- Python Django

Python | Reversing a String >>> x = 'PythonWorld' >>> print(x[: : -1]) dlroWnohtyP  

Last updated 3 months, 2 weeks ago | 74 views

Tags:- Python Django

 Python | In-place swapping of two numbers >>> a, b = 10, 20 >>> print(a, b) 10 20 >>> a, b = b, a >>> print(a, b) 20 10  

Last updated 3 months, 2 weeks ago | 74 views

Tags:- Python Django

Git | Undo the most recent local commits Bellow command is used to reset the last local commit. git reset HEAD~        

Last updated 3 months, 2 weeks ago | 85 views

Tags:- Git

In Django, static files are the files that serve the purpose of additional purposes such as images, CSS, or JavaScript files. Static files managed by “django.contrib.staticfiles”. There are three main things to  set up static …

Last updated 3 months, 2 weeks ago | 91 views

Tags:- Django

Compared to other frameworks, Django offers more code reusability. As Django is a combination of apps, copying those apps from one directory to another with some tweaks to the settings.py file won't need much time …

Last updated 3 months, 2 weeks ago | 104 views

Tags:- Django

Django follows a Model-View -Template (MVT) architecture which is a variant of the MVC architecture.  Model: Logical data structure behind the entire app and signified by a database. A model is used in Django to …

Last updated 3 months, 2 weeks ago | 80 views

Tags:- Django

Windows | Set path and environment variables in Windows 11 Press the + to access the Power User Task Menu. In the Power User Task Menu, select the System option. In the System window, scroll to the bottom and click the About option. In the System …

Last updated 3 months, 2 weeks ago | 88 views

Tags:- Windows

Windows | Set path and environment variables in Windows 2000 and Windows XP On the desktop, right-click the Computer icon and select Properties. or Press the  and right-click the Computer option in the Start menu, and select Properties. In the System Properties window, click the Advanced tab. In the Advanced tab, click …

Last updated 3 months, 2 weeks ago | 76 views

Tags:- Windows

Windows | Set path and environment variables in Windows Vista and Windows 7 On the desktop, right-click the Computer icon and select Properties. or Press the  and right-click the Computer option in the Start menu, and select Properties. Click the Advanced System Settings link in the left column. In …

Last updated 3 months, 2 weeks ago | 81 views

Tags:- Windows

Windows | Set path and environment variables in Windows 8 Press the + to access the Power User Task Menu Now, select the System option. Click the Advanced System Settings link in the left column. In the Advanced tab, click the  button. In the Environment Variables window highlight …

Last updated 3 months, 2 weeks ago | 83 views

Tags:- Windows

A few common security issues that can be avoided by using Django are: Clickjacking Cross-site scripting and SQL injection

Last updated 3 months, 2 weeks ago | 77 views

Tags:- Python