德尔福软件试题ZZ

2024-04-23 03:08
文章标签 软件 试题 zz 德尔福

本文主要是介绍德尔福软件试题ZZ,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!

德尔福软件试题ZZ
shury 发表于 2004-12-6 14:27:00

1. How do you code an infinite loop in C?
2. Volatile:
   a) What does the keyword volatile mean? Give an example
   b) Can a parameter be both const and volatile? Give an example
   c) Can a pointer be volatile? Give an example
3.  What are the values of a, b, and c after the following instructions:
    int a=5, b=7, c;
    c = a+++b;
4,  What do the following declarations mean?
        a) const int a;
        b) int const a;
        c) const int *a;
        d) int * const a;
        e) int const * a const;
5.  Which of the following statements describe the use of the keyword
static?
a) Within the body of a function: A static variable maintains its value
      between function revocations


  b) Within a module: A static variable is accessible by all functions
      within that module
  c) Within a module: A static function can only be called by other
            functions within that module
6.  Embedded systems always require the user to manipulate bits in
registers or variables. Given an integer variable a, write two code fragments.
The first should set bit 5 of a. The second shnuld clear bit 5 of a. In both
cases, the remaining bits should be unmodified.
7.  What does the following function return?
      char foo(void)
      {
                 unsigned int a = 6;
                 iht b = -20;
                 char c;
                 (a+b > 6) ? (c=1): (c=0);
                 return c;
      }
8.  What values are printed when the following C program is executed?
      int i = 8;
      void main(void)
      (

 

9.  What will be the output of the following C code?
     main()
     {
            int k, num= 30;
            k =(num > 5 ? (num <=10 ? 100:200): 500);
            printf("%d", k);
     }
10. What will the following C code do?
        int *ptr;
        ptr =(int *)Ox67a9;
        *ptr = Oxaa55;
11. What will be the output of the follow C code?
     #define product(x) (x*x)
     main()
     {
         int i = 3, j, k;
         j = product(i++);
         k = product(++i);
         printf("%d %d",j,k);
     }
12. Simplify the following Boolean expression
      !((i ==12) || (j > 15))


13. How many flip-flop circuits are needed to divide by 16?
14. Provides 3 properties that make an OS, a RTOS?
15. What is pre-emption?
16. Assume the BC register value is 8538H, and the DE register
value is 62A5H.Find the value of register BC after the following
assembly operations:
        MOV A,C
        SUB E
        MOV C,A
        MOV A,B
        SBB D
        MOV B,A
17.In the Assembly code shown below
  LOOP: MVI C,78H
        DCR C
        JNZ LOOP
        HLT
How many times is the DCR C Operation executed?
18.Describe the most efficient way(in term of execution time
and code size) to divide a number by 4 in assembly language
19.what value is stored in m in the following assembly language code
fragment if n=7?


        LDAA #n
LABEL1: CMPA #5
        BHI  L3
        BEQ  L2
        DECA
        BRA  L1
LABEL2: CLRA
LABEL3: STAA #m
20. What is the state of a process if a resource is not
available?
21. Using the #define statement, how would you
declare a manifest constant that returns the
number of seconds in a year? Disregard leap
years in your answer.
22. Interrupts are an important part of embedded
systems. Consequently, many compiler vendors
offer an extension to standard C to support interrupts.
Typically, the keyword is __interrupt. The following
code uses __interrupt to define an interrupt service
routine (ISR). Point out problems in the code.

__interrupt double compute_area (double radius)


          double area = PI * radius * radius;
          printf("/nArea = %f", area);
          return area;

 
 

这篇关于德尔福软件试题ZZ的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!


原文地址:
本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.chinasem.cn/article/927619

相关文章

Qt 设置软件版本信息的实现

《Qt设置软件版本信息的实现》本文介绍了Qt项目中设置版本信息的三种常用方法,包括.pro文件和version.rc配置、CMakeLists.txt与version.h.in结合,具有一定的参考... 目录在运行程序期间设置版本信息可以参考VS在 QT 中设置软件版本信息的几种方法方法一:通过 .pro

安装centos8设置基础软件仓库时出错的解决方案

《安装centos8设置基础软件仓库时出错的解决方案》:本文主要介绍安装centos8设置基础软件仓库时出错的解决方案,具有很好的参考价值,希望对大家有所帮助,如有错误或未考虑完全的地方,望不吝赐... 目录安装Centos8设置基础软件仓库时出错版本 8版本 8.2.200android4版本 javas

如何确定哪些软件是Mac系统自带的? Mac系统内置应用查看技巧

《如何确定哪些软件是Mac系统自带的?Mac系统内置应用查看技巧》如何确定哪些软件是Mac系统自带的?mac系统中有很多自带的应用,想要看看哪些是系统自带,该怎么查看呢?下面我们就来看看Mac系统内... 在MAC电脑上,可以使用以下方法来确定哪些软件是系统自带的:1.应用程序文件夹打开应用程序文件夹

Ubuntu 怎么启用 Universe 和 Multiverse 软件源?

《Ubuntu怎么启用Universe和Multiverse软件源?》在Ubuntu中,软件源是用于获取和安装软件的服务器,通过设置和管理软件源,您可以确保系统能够从可靠的来源获取最新的软件... Ubuntu 是一款广受认可且声誉良好的开源操作系统,允许用户通过其庞大的软件包来定制和增强计算体验。这些软件

2024年流动式起重机司机证模拟考试题库及流动式起重机司机理论考试试题

题库来源:安全生产模拟考试一点通公众号小程序 2024年流动式起重机司机证模拟考试题库及流动式起重机司机理论考试试题是由安全生产模拟考试一点通提供,流动式起重机司机证模拟考试题库是根据流动式起重机司机最新版教材,流动式起重机司机大纲整理而成(含2024年流动式起重机司机证模拟考试题库及流动式起重机司机理论考试试题参考答案和部分工种参考解析),掌握本资料和学校方法,考试容易。流动式起重机司机考试技

软件设计师备考——计算机系统

学习内容源自「软件设计师」 上午题 #1 计算机系统_哔哩哔哩_bilibili 目录 1.1.1 计算机系统硬件基本组成 1.1.2 中央处理单元 1.CPU 的功能 1)运算器 2)控制器 RISC && CISC 流水线控制 存储器  Cache 中断 输入输出IO控制方式 程序查询方式 中断驱动方式 直接存储器方式(DMA)  ​编辑 总线 ​编辑

【STM32】SPI通信-软件与硬件读写SPI

SPI通信-软件与硬件读写SPI 软件SPI一、SPI通信协议1、SPI通信2、硬件电路3、移位示意图4、SPI时序基本单元(1)开始通信和结束通信(2)模式0---用的最多(3)模式1(4)模式2(5)模式3 5、SPI时序(1)写使能(2)指定地址写(3)指定地址读 二、W25Q64模块介绍1、W25Q64简介2、硬件电路3、W25Q64框图4、Flash操作注意事项软件SPI读写W2

CSP 2023 提高级第一轮 CSP-S 2023初试题 完善程序第二题解析 未完

一、题目阅读 (最大值之和)给定整数序列 a0,⋯,an−1,求该序列所有非空连续子序列的最大值之和。上述参数满足 1≤n≤105 和 1≤ai≤108。 一个序列的非空连续子序列可以用两个下标 ll 和 rr(其中0≤l≤r<n0≤l≤r<n)表示,对应的序列为 al,al+1,⋯,ar​。两个非空连续子序列不同,当且仅当下标不同。 例如,当原序列为 [1,2,1,2] 时,要计算子序列 [

免费也能高质量!2024年免费录屏软件深度对比评测

我公司因为客户覆盖面广的原因经常会开远程会议,有时候说的内容比较广需要引用多份的数据,我记录起来有一定难度,所以一般都用录屏工具来记录会议内容。这次我们来一起探索有什么免费录屏工具可以提高我们的工作效率吧。 1.福晰录屏大师 链接直达:https://www.foxitsoftware.cn/REC/  录屏软件录屏功能就是本职,这款录屏工具在录屏模式上提供了多种选项,可以选择屏幕录制、窗口

HomeBank:开源免费的个人财务管理软件

在个人财务管理领域,找到一个既免费又开源的解决方案并非易事。HomeBank&nbsp;正是这样一个项目,它不仅提供了强大的功能,还拥有一个活跃的社区,不断推动其发展和完善。 开源免费:HomeBank 是一个完全开源的项目,用户可以自由地使用、修改和分发。用户友好的界面:提供直观的图形用户界面,使得非技术用户也能轻松上手。数据导入支持:支持从 Quicken、Microsoft Money