SlideShare a Scribd company logo
2
Most read
12
Most read
18
Most read
PYTHON
MIDTERM PROJECT
WORD-CHAR COUNTER WITH SIMPLE GUI
MAHMUT KAMALAK
16290155
BIOMEDICAL ENGINEERING
OBJECTIVE
In this python programming project, I applied to count the
total words and characters in a string. The program will take the string as input from
the user, count the words and characters and then it will print out the results on the
GUI.
OVERVIEW –
BLANK
DIAGRAM
What is Tkinter ?
 The tkinter package (“Tk interface”) is the standard Python interface to the Tk GUI
toolkit. Both Tk and tkinter are available on most Unix platforms, as well as on
Windows systems. (Tk itself is not part of Python; it is maintained at ActiveState.)
 Tkinter is lightweight and relatively painless to use compared to other frameworks.
This makes it a compelling choice for building GUI applications in Python,
especially for applications where a modern sheen is unnecessary, and the top
priority is to build something that’s functional and cross-platform quickly.
Step -1
 To use Tkinter , firstly we have to import Tkinter modules.
Step 2
 Opening the new empty window with ‘Tk()’
 Giving a name to window with ‘title()’
 Adjusting the background color with ‘configure()’
 Adjusting the size of window with ‘geometry()’
 Arranging the permissions to resizable with ‘resizable()’
window
Step 3
 I created the TEXT label with adjusting of ; Label()
1. Name of label ---- text=‘ ‘
2. Background color----bg=‘ ‘
3. Word color----fg=‘ ’
4. Size of label----width=‘’
5. Position of label on the window--- grid()
Code and Window for Step-3
w
i
n
d
o
w
Step-4
 I created entry label with ‘Entry()’
 Configured to arrange the entry type with ‘StringVar()’
 Adjusting location of label on the window with ‘grid()’
window
Step -5
 I created the ‘Character’ and ‘word’ labels with adjusting of ; Label()
1. Name of label ---- text=‘ ‘
2. Background color----bg=‘ ‘
3. Word color----fg=‘ ’
4. Size of label----width=‘’
5. Position of label on the window--- grid()
Code and Window for Step-5
windo
w
Step-6
 I created entry labels with ‘Entry()’ for char and word
 Configured to arrange the entry type with ‘DoubleVar()’ to be able integer values for char and
word results.
 Adjusting location of label on the window with ‘grid()’
window
Step -7
 Buttons ,which are clear and calculate, were created to call functions and buttons were configured
with ‘Button()’
 Location of buttons were adjusted with ‘grid()’
 Clear button calls ‘clear’ function.
 Calculate button calls ‘calculatee’ function
Code and Window for Step -7
Step-8
 To calculate number of words of the input text, ‘calculate’ function was defined.
 With get() function , string is getting from ‘ft_entry’.
 And, with using str() function, we get string values.
 In addition, values is seperated word by word from sentences by using ‘split()’
function,and we get word list, like figure.i and figure.o
 Number of words is calculated by using len() function.
 Finally , we send the number of words to word label with ‘set()’ func.
Figure.i Figure.o
İnput to output
for split()
Step -9
 On the continue of ‘calculatee’ function; in the list ,which is created by split() before, the every
word is entried to len() function and number of characters are sent to mt_value2 by set() function.
 On the other hand , ‘clear’ function was defined to clear input and outputs by using set(‘’).
Codes for Step -8 and Step-9
Example -1
 INPUT : ‘mahmut kamalak 16290155’
 OUTPUT :
Example -2
 INPUT : ‘I am learning python programming’
 OUTPUT :
Example -3
 INPUT : In this python programming tutorial, we will learn how to count the
total words and characters in a string. The program will take the string as input from the user,
count the words and characters and then it will print out the result.
 OUTPUT :
FULL CODE SOURCE -1
FULL CODE SOURCE -2
FULL CODE SOURCE -3
REFERENCES
 https://docs.python.org/3/library/tkinter.html
 https://www.lucidchart.com/ ( designing blank diagram)

More Related Content

DOCX
Online Book Donation System Project Report (Android)
DOCX
Documentation of railway reservation system
PPTX
OpenGL Mini Projects With Source Code [ Computer Graphics ]
DOCX
Airline Reservation System Documentation
PPTX
Block Truncation Coding
PPTX
Arq Protocols
DOCX
Synopsis on railway reservation system
DOCX
Online bus ticket booking
Online Book Donation System Project Report (Android)
Documentation of railway reservation system
OpenGL Mini Projects With Source Code [ Computer Graphics ]
Airline Reservation System Documentation
Block Truncation Coding
Arq Protocols
Synopsis on railway reservation system
Online bus ticket booking

What's hot (20)

PPTX
online bus ticket booking system
PPTX
Online food ordering System projectppt.pptx
PPTX
Online Movie or theater ticket booking system Details Requirement.
PPTX
Email HTTP And FTP
PDF
Frequency Domain Filtering of Digital Images
PPTX
Depth Buffer Method
PPTX
Basic web security model
PDF
Final Year Game Project Report - Riko: The Aventurer
DOC
Hostel management system srs
PPTX
JPEG Image Compression
PPTX
Railway Reservation System - Requirement Engineering
PPTX
go back n protocol
DOCX
Online railway reservation system
PDF
Railway reservation system
PPTX
GO BACK N PROTOCOL
PPTX
Histogram Specification or Matching Problem
PDF
CNNs: from the Basics to Recent Advances
PDF
Canteen automation system (updated) revised
PPTX
online bus ticket booking system
PDF
Image Sensing and Aquisition
online bus ticket booking system
Online food ordering System projectppt.pptx
Online Movie or theater ticket booking system Details Requirement.
Email HTTP And FTP
Frequency Domain Filtering of Digital Images
Depth Buffer Method
Basic web security model
Final Year Game Project Report - Riko: The Aventurer
Hostel management system srs
JPEG Image Compression
Railway Reservation System - Requirement Engineering
go back n protocol
Online railway reservation system
Railway reservation system
GO BACK N PROTOCOL
Histogram Specification or Matching Problem
CNNs: from the Basics to Recent Advances
Canteen automation system (updated) revised
online bus ticket booking system
Image Sensing and Aquisition
Ad

Similar to Char word counter in Python with simple gui - PROJECT (20)

PDF
Report for DIGITAL CLOCK 12011042 Manoj.pdf
PPTX
Python ppt
PPTX
Unit2 input output
PPTX
Chapter1 python introduction syntax general
PDF
python-online&offline-training-in-kphb-hyderabad (1) (1).pdf
PDF
Python Manuel-R2021.pdf
PDF
Python Programming-I Journal labs manual
PPTX
Python knowledge ,......................
PPTX
Chapter04.pptx
PPTX
Objects and Graphics
PDF
R Markdown Reference Guide for reproducible research
PPTX
unit (1)INTRODUCTION TO PYTHON course.pptx
PPTX
tkinterpptxguipythonImport it is named ‘tkinter
PPTX
Python Course Basic
PDF
Introduction to Python - Jouda M Qamar.pdf
PDF
Basic Concepts in Python
PPT
Sample Lab Orientation in Python orientation
PDF
GUI Programming with TKinter and Tkinter Widgets.pdf
PDF
Revision of the basics of python1 (1).pdf
PDF
Advanced Web Technology ass.pdf
Report for DIGITAL CLOCK 12011042 Manoj.pdf
Python ppt
Unit2 input output
Chapter1 python introduction syntax general
python-online&offline-training-in-kphb-hyderabad (1) (1).pdf
Python Manuel-R2021.pdf
Python Programming-I Journal labs manual
Python knowledge ,......................
Chapter04.pptx
Objects and Graphics
R Markdown Reference Guide for reproducible research
unit (1)INTRODUCTION TO PYTHON course.pptx
tkinterpptxguipythonImport it is named ‘tkinter
Python Course Basic
Introduction to Python - Jouda M Qamar.pdf
Basic Concepts in Python
Sample Lab Orientation in Python orientation
GUI Programming with TKinter and Tkinter Widgets.pdf
Revision of the basics of python1 (1).pdf
Advanced Web Technology ass.pdf
Ad

Recently uploaded (20)

PPT
Project quality management in manufacturing
PPTX
CH1 Production IntroductoryConcepts.pptx
PPTX
bas. eng. economics group 4 presentation 1.pptx
PPTX
CARTOGRAPHY AND GEOINFORMATION VISUALIZATION chapter1 NPTE (2).pptx
PDF
Operating System & Kernel Study Guide-1 - converted.pdf
DOCX
573137875-Attendance-Management-System-original
PPTX
Engineering Ethics, Safety and Environment [Autosaved] (1).pptx
PDF
PPT on Performance Review to get promotions
PDF
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
PPTX
FINAL REVIEW FOR COPD DIANOSIS FOR PULMONARY DISEASE.pptx
PPTX
Current and future trends in Computer Vision.pptx
PPTX
OOP with Java - Java Introduction (Basics)
PPTX
Artificial Intelligence
PPTX
UNIT-1 - COAL BASED THERMAL POWER PLANTS
PDF
July 2025 - Top 10 Read Articles in International Journal of Software Enginee...
PDF
R24 SURVEYING LAB MANUAL for civil enggi
PDF
Embodied AI: Ushering in the Next Era of Intelligent Systems
PDF
PRIZ Academy - 9 Windows Thinking Where to Invest Today to Win Tomorrow.pdf
PPT
introduction to datamining and warehousing
PDF
Enhancing Cyber Defense Against Zero-Day Attacks using Ensemble Neural Networks
Project quality management in manufacturing
CH1 Production IntroductoryConcepts.pptx
bas. eng. economics group 4 presentation 1.pptx
CARTOGRAPHY AND GEOINFORMATION VISUALIZATION chapter1 NPTE (2).pptx
Operating System & Kernel Study Guide-1 - converted.pdf
573137875-Attendance-Management-System-original
Engineering Ethics, Safety and Environment [Autosaved] (1).pptx
PPT on Performance Review to get promotions
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
FINAL REVIEW FOR COPD DIANOSIS FOR PULMONARY DISEASE.pptx
Current and future trends in Computer Vision.pptx
OOP with Java - Java Introduction (Basics)
Artificial Intelligence
UNIT-1 - COAL BASED THERMAL POWER PLANTS
July 2025 - Top 10 Read Articles in International Journal of Software Enginee...
R24 SURVEYING LAB MANUAL for civil enggi
Embodied AI: Ushering in the Next Era of Intelligent Systems
PRIZ Academy - 9 Windows Thinking Where to Invest Today to Win Tomorrow.pdf
introduction to datamining and warehousing
Enhancing Cyber Defense Against Zero-Day Attacks using Ensemble Neural Networks

Char word counter in Python with simple gui - PROJECT

  • 1. PYTHON MIDTERM PROJECT WORD-CHAR COUNTER WITH SIMPLE GUI MAHMUT KAMALAK 16290155 BIOMEDICAL ENGINEERING
  • 2. OBJECTIVE In this python programming project, I applied to count the total words and characters in a string. The program will take the string as input from the user, count the words and characters and then it will print out the results on the GUI.
  • 4. What is Tkinter ?  The tkinter package (“Tk interface”) is the standard Python interface to the Tk GUI toolkit. Both Tk and tkinter are available on most Unix platforms, as well as on Windows systems. (Tk itself is not part of Python; it is maintained at ActiveState.)  Tkinter is lightweight and relatively painless to use compared to other frameworks. This makes it a compelling choice for building GUI applications in Python, especially for applications where a modern sheen is unnecessary, and the top priority is to build something that’s functional and cross-platform quickly.
  • 5. Step -1  To use Tkinter , firstly we have to import Tkinter modules.
  • 6. Step 2  Opening the new empty window with ‘Tk()’  Giving a name to window with ‘title()’  Adjusting the background color with ‘configure()’  Adjusting the size of window with ‘geometry()’  Arranging the permissions to resizable with ‘resizable()’ window
  • 7. Step 3  I created the TEXT label with adjusting of ; Label() 1. Name of label ---- text=‘ ‘ 2. Background color----bg=‘ ‘ 3. Word color----fg=‘ ’ 4. Size of label----width=‘’ 5. Position of label on the window--- grid()
  • 8. Code and Window for Step-3 w i n d o w
  • 9. Step-4  I created entry label with ‘Entry()’  Configured to arrange the entry type with ‘StringVar()’  Adjusting location of label on the window with ‘grid()’ window
  • 10. Step -5  I created the ‘Character’ and ‘word’ labels with adjusting of ; Label() 1. Name of label ---- text=‘ ‘ 2. Background color----bg=‘ ‘ 3. Word color----fg=‘ ’ 4. Size of label----width=‘’ 5. Position of label on the window--- grid()
  • 11. Code and Window for Step-5 windo w
  • 12. Step-6  I created entry labels with ‘Entry()’ for char and word  Configured to arrange the entry type with ‘DoubleVar()’ to be able integer values for char and word results.  Adjusting location of label on the window with ‘grid()’ window
  • 13. Step -7  Buttons ,which are clear and calculate, were created to call functions and buttons were configured with ‘Button()’  Location of buttons were adjusted with ‘grid()’  Clear button calls ‘clear’ function.  Calculate button calls ‘calculatee’ function
  • 14. Code and Window for Step -7
  • 15. Step-8  To calculate number of words of the input text, ‘calculate’ function was defined.  With get() function , string is getting from ‘ft_entry’.  And, with using str() function, we get string values.  In addition, values is seperated word by word from sentences by using ‘split()’ function,and we get word list, like figure.i and figure.o  Number of words is calculated by using len() function.  Finally , we send the number of words to word label with ‘set()’ func. Figure.i Figure.o İnput to output for split()
  • 16. Step -9  On the continue of ‘calculatee’ function; in the list ,which is created by split() before, the every word is entried to len() function and number of characters are sent to mt_value2 by set() function.  On the other hand , ‘clear’ function was defined to clear input and outputs by using set(‘’).
  • 17. Codes for Step -8 and Step-9
  • 18. Example -1  INPUT : ‘mahmut kamalak 16290155’  OUTPUT :
  • 19. Example -2  INPUT : ‘I am learning python programming’  OUTPUT :
  • 20. Example -3  INPUT : In this python programming tutorial, we will learn how to count the total words and characters in a string. The program will take the string as input from the user, count the words and characters and then it will print out the result.  OUTPUT :