itgle.com
参考答案和解析
正确答案:C
更多“Python中若定义object=(1, 2, 3, 4, 5),则print(object[:3])输出() ”相关问题
  • 第1题:

    Traditional structured analysis techniques focus upon the flow of(1)within a system. Object-oriented analysis emphasizes the building of real-world models, It examines requirements from the perspective of the classes and objects found in the vocabulary of the(2)domain.Traditional system design method emphasizes the proper and effective structure of a complex system. Object-oriented design method encompasses the process of object- oriented decomposition and a(3)for depicting both logical and physical as well as static and dynamic models of the system under design.Object-oriented programming is a method of implementation in which programs are organized as cooperative collections of objects, each of which represents an(4)of some class, and whose classes are all members of a hierarchy of classes united via(5)relationships.

    A.control

    B.program

    C.data

    D.reference


    正确答案:C
    解析:传统的结构化分析技术关注的是系统的数据流程,面向对象分析强调对现实世界的建模,它从问题域中的类和对象的角度来检查需求。传统系统设计方法强调的是复杂系统的适当和有效的结构,面向对象设计方法包括面向对象的分解过程和一个描述待设计系统的物理和逻辑模型,以及动态和静态模型的符号。面向对象的程序设计是这样一种实现方法,程序是协同对象的组织,每个对象都代表一些类的一个实例,这些类是通过继承关系联系起来的类层次的所有成员。

  • 第2题:

    12、在Python中,numbers=[1, 2, 3, 4, 5],执行print(numbers[:4])的结果为

    A.[4]

    B.[5]

    C.[1, 2, 3, 4]

    D.[1, 2, 3, 4, 5]


    range

  • 第3题:

    Python中的语句: temp=['a','1',2,3,None,] print(len(temp)) 其输出结果是_____

    A.3

    B.4

    C.5

    D.6


    5

  • 第4题:

    Object中定义的线程同步与交换的方法有几种? ( )

    A.1种

    B.2种

    C.3种

    D.4种


    正确答案:C
    解析:Object中定义了Runnable接口,它定义的线程同步与交换的方法有:wait()、 notify()以及notifyAll(),即3种。

  • 第5题:

    1. Python语句 print(1,2,3,4,5,sep='-',end='!')的输出结果是___________


    1-2-3-4-5!