WGU D522 EXAM GUIDE ACTUAL EXAM QUESTIONS AND VERIFIED ACCURATE SOLUTION (DETAILED & ELABORATED) |GET IT 100% ACCURATE!! 2025 TEST!!

0.0(0)
studied byStudied by 0 people
0.0(0)
full-widthCall Kai
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/171

encourage image

There's no tags or description

Looks like no tags are added yet.

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

172 Terms

1
New cards

Python

interpreted programming language known for its simplicity, readability, and versatility

supports multiple programming paradigms, including procedural, object-oriented, and functional programming, making it adaptable to different coding styles.

2
New cards

Python is

readable

dynamically typed

extensive standard library

cross plat

versatile

interpreted nature

3
New cards

Programming Paradigm

a fundamental style or approach to programming that dictates how tasks should be structured and executed in each programming language. It encompasses principles, concepts, and patterns that guide the design and organization of code.

4
New cards

imperative/procedural programming

focuses on describing a sequence of steps to perform a task, procedures or routines.

5
New cards

object-oriented programming (OOP)

organizes code around objects, which encapsulate data and behavior

6
New cards

functional programming

emphasizes the use of functions and immutable data for computation

7
New cards

declarative programming

describes what the program should accomplish without specifying how to achieve it

8
New cards

event-driven programming

reacts to events and user actions, triggering corresponding functions

9
New cards

logic programming

defines a set of logical conditions and lets the system deduce solutions

10
New cards

indentation

defines blocks of code. crucial for structure and nesting of code blocks

(4 spaces)

11
New cards

comments

#

ignored by interpreter, for humans

12
New cards

Variable

used to store data, created by assigning a value to a name

13
New cards

Data Types

integers, floats, strings, lists, tuples, dictionaries

14
New cards

conditional statements

if, else, elif (else if)

15
New cards

Classes

(also objects) fundamental to object oriented programming in python.

16
New cards

print ()

used to output data to the console

print ("hello")

17
New cards

functions

defined using def

def greet(name):

print ("Hello, name")

18
New cards

run python script in cmd prompt

python script.py

19
New cards

How to run phython script in Python3

python3 script.py

20
New cards

Integrated Development Environments (IDEs)

provide a more user-friendly environment for coding, debugging, and running Python scripts

21
New cards

Markdown file

simple format used frequently to add styled text, images, code snippets and more to coding repos serving as documentation

human readable

22
New cards

.md

markdown file

23
New cards

Consistent Indentation

All statements within the same block must be indented by the same number of spaces.

24
New cards

input()

function, storing user entered info as strings

25
New cards

output()

functions, allowing the presentation of results or messages

26
New cards

format()

method, enhances output formatting by embedding variables in strings

27
New cards

file I/O

through the open() functions enabling reading from and writing to external files.

28
New cards

len ()

determines the length of a sequence

29
New cards

type ()

returns the type of an object

30
New cards

int (), float (), str ()

converts values to integers, floats, or strings

31
New cards

max (), min()

returns the max or min value from a sequences

32
New cards

sum ()

finds the sum of elements in a sequence

33
New cards

abs ()

returns the absolute value of a number

34
New cards

range ()

generates a sequence of numbers

35
New cards

sorted ()

returns a sorted list from an iterable

36
New cards

any (), all()

checks if any or all elemebts in an interable are true

37
New cards

map (), filter ()

applies a function to elements or filters elements based on a functions

38
New cards

open (), read (), write ()

handles file I/O operations

39
New cards

dir ()

lists the names in the current scope or attributes of an object

40
New cards

help ()

provides help info about an object or Python

41
New cards

interactive shell

enables the execution of python code interactively, providing tools for creating, opening, and saving projects.

42
New cards

version control integration

supports integration with version control sys like Git for effcient collaboration and code versioning

43
New cards

code navigation

facilitates easy navigation through large codebases by offering features such as code folding, code outlining, and quick navigation to definitions.

44
New cards

integrated documentation

provides access to documentation for Python libraries and modules directly within the IDE

45
New cards

code profiling

Allows developers to analyze code performance and identify areas for optimization

46
New cards

Problem solving process

analyze problem

develop algo

write code

test and debug

47
New cards

python is dynamically typed

variable types in python are determined at runtime

48
New cards

Purpose of code editor in python IDE

provide a text editor offering syntax highlighting, code completion, and indentation.

49
New cards

Python variables

serving as placeholders to store and manage data. In Python, you don't need to explicitly declare a variable's data type; it dynamically infers it based on the assigned value.

50
New cards

Symbolic Names

refer to names or identifiers that represent values, objects, or entities.

51
New cards

variable name rules

number, letters, _

start with letter or _

cannot be a python keyword

52
New cards

assign multiple variables

x, y, z = "one", "two", "three"

53
New cards

assigning the same value multiple variables

hi = hello = hey = "greeting"

54
New cards

printing multiple variables with , and +

+ will combine strings, and also numbers but not together

, will combine strings and numbers together.

55
New cards

inside a function

means the code is part of a specific function block. Variables defined inside the function have local scope, and the function executes when called.

56
New cards

outside a function

means the code is not part of any specific function block. Variables defined outside functions generally have a global scope and can be accessed throughout the program

57
New cards

function (local)

not accessible outside, promoting encapsulation.

58
New cards

Global Variables

declared outside of functions and can be accessed from any part of the program

59
New cards

core data types

integers, floats, strings

60
New cards

Lists and Tuples

facilitate the organization of multiple elements

61
New cards

dictionaires

enable key value pair storage.

62
New cards

str:

string

63
New cards

int:

integer

64
New cards

float:

floating-point type

65
New cards

boolean

true or falseu

is_true=true

is_false=false

66
New cards

list

ordered, mutalble sequence

[ ]

67
New cards

tuple

ordered, immutable sequence

( )

68
New cards

set:

unordered, mutable collection of unique elements

69
New cards

frozenset:

unchangeable set

70
New cards

dict:

dictionary, an unordered collection of key-pair values

71
New cards

int_num = int(float_num)

converting something to integer, int

same for x = float(y)

x = round(y)

x=abs(y) - absoluite value

72
New cards

You can create multiple strings with

three quotes

73
New cards

Repitition (*)

repeat a string

74
New cards

concatenation (+)

combine two strings

75
New cards

Indexing ([])

accessing individual characters by position. First pos is 0.

76
New cards

(f-strings)

stands for format. Replaces the name of any variable in braces with its value.

77
New cards

\n

\t

new line

new tab

78
New cards

string slicing

refers to the technique of extracting a portion of a string by specifying a range of indices

start, stop, and step

79
New cards

string [start:stop:step]

start is where slicing begins

-if not provided default to beginning of string

stop is where slicing ends

- if not provided default to end of string

step or stride between characters

- if not provided default to 1

80
New cards

immutable

cannot be changed

81
New cards

mutable

can be changed

82
New cards

you can modify strings with

replace ()

upper ()

lower ()

83
New cards

count ()

counts the occurrences of a substring in the given string

84
New cards

strip ()

removes leading and trailing whitespaces

85
New cards

lstrip ()

removes leading white spaces

86
New cards

rstrip ()

removes trailing whitepsaces

87
New cards

+=

shorthand for concatenation and assignment

88
New cards

greeting = "Hello "

greeting =+ "Python!"

print (greeting)

Hello Python

89
New cards

join ()

combine strings from an iterable (list)

90
New cards

positional arguments

arguments that are passed to a function or method in a specific order.

91
New cards

named arguments

keyword arguments, passed to a function or method by explicitly stating the name of the parameter and its value.

92
New cards

assignment operators

=, +=, -=, =, /=, %=, //=, *=

93
New cards

membership operators

in, not in

94
New cards

identity operators

is, is not

95
New cards

modulus %

returns the remainder

96
New cards

floor division //

performs division and rounds down to the nearest whole number.

97
New cards

bitwise shift << >>

lower than arthimetic operations

98
New cards

Exponentiation **

next highest

99
New cards

bitwise AND &

lower than shifts

100
New cards

bitwise XOR ^

lower than AND