전체 글
-
[OOP] class 클래스 개념 및 구성요소🐍 파이썬/파이썬 기본 문법 2022. 7. 27. 11:30
What is "Object-oriented" programming? •"Object-orientation" is just one of many programming paradigms : Our world is made up of "things", so it is a good model of the world! •Practical considerations: -Facilitates testing(we can test the classes separately) -Encourages reuse(we can reuse classes defined by other people) -Users don’t need to know the inner workings of a class, they just rely on ..
-
-
-
[Intro to C] C as a systems programming languageSystem Programming 2022. 7. 25. 03:43
C is a good choice for ... •Operating System developers •Embedded systems •People who reallycare about speed •Authors of security exploits C has ... • No objects, classes, features, methods, or interfaces - Only functions/procedures - We will see function pointers later… • No fancy built-in types - Mostly just what the hardware provides - Type constructors to build structured types • No exceptio..
-
[Dictionary] map key and value🐍 파이썬/파이썬 연습문제 2022. 7. 20. 09:11
문제: Implement a function that receives a list of Tuples, where every Tuple takes the form: (,,). The function should return two Dictionaries in a Tuple. The first dictionary should map from Actor to Movies, the second dictionary should map from Year to Movies. Example movie_maps( [("Keanu Reeves",Reeves","The Matrix", 1999 ),("Keanu Reeves", Bill Ted's Excellent Adventure", 1989)..
-
[list] find minimum in array🐍 파이썬/파이썬 연습문제 2022. 7. 20. 09:01
문제: Implement a function that receives a list of numbers as an argument and returns the index of the minimum value and the actual minimum value as a Tuple. Return None for an empty list Example find_min([3, 2, 5, 1, 7] should return (3, 1) def find_min(l): if l == []: return None min = l[0] min_i = 0 for i, num in enumerate(l): if num < min : min = num min_i = i retrun (min_i, min) print find_mi..