`
yaojingguo
  • 浏览: 207918 次
  • 性别: Icon_minigender_1
  • 来自: 北京
社区版块
存档分类
最新评论

Array and its first element

 
阅读更多

#include <stdio.h>

struct rx_desc {
	int len;
	int status;
};

struct rx_desc rx_ring[2];

int main(int argc, const char *argv[]) {
	struct rx_desc* rx;

	// Intialization
	rx_ring[0].len = 1;
	rx_ring[0].status = 10;
	rx_ring[1].len = 2;
	rx_ring[1].status = 20;
	rx = &rx_ring[0];

	printf("%d\n", rx_ring->len);
	printf("%d\n", rx->len);

	return 0;
}
 
分享到:
评论

相关推荐

    实验三:数组及其应用.doc

    3. The third program finds the maximum element in a 2D array and prints its position and value. 4. The fourth program concatenates two strings using the `strcat` function. 5. The fifth program ...

    Prototype Cheat Sheet

    - **`recursivelyCollect(element, property)`**: Recursively collects values of a property from an element and its descendants. - **`relativize(element)`**: Converts the positioning of an element to ...

    C第六章数组指针与字符串PPT学习教案.pptx

    例如:a[0][1] refers to the element at the first row and second column of a 2D array. 3. 数组的存储:一维数组元素在内存中顺序、连续存储。二维数组元素在内存按行存放,每行元素按列下标由小到大顺次存放。...

    Algorithms and Data Structures - Niklaus Wirth

    - **Sorting by Straight Selection**: Selects the smallest (or largest) element and moves it to its final position. - **Sorting by Straight Exchange**: Exchanges adjacent elements if they are out of ...

    基于FPGA的简易逻辑分析仪的设计与仿真完整设计.pdf

    In the first chapter, the background of the topic selection is discussed, highlighting the importance of logic analyzers in digital system debugging and the role of FPGAs in providing flexible and ...

    折半查找 binarySearch

    A binary search finds the median element in a list, compares its value to the one you are searching for, and determines if it’s greater than, less than, or equal to the one you want. A guess that ...

    Algorithms in C++, Parts 1-4: Fundamentals, Data Structures, Sorting, Searching

    Key operations include `find` (determining which subset an element belongs to) and `union` (merging two subsets into one). 4. **Perspective**: The chapter provides a perspective on the importance of...

    Collections

    They also offer convenient ways to search for elements using methods like `contains(_:)` and `firstIndex(of:)`. ##### Sorting Arrays Arrays can be sorted based on specific criteria using various ...

    Sortable前端框架

    You can use any element for the list and its elements, not just `ul`/`li`. Here is an [example with `div`s](http://jsbin.com/qumuwe/edit?html,js,output). --- ### Options ```js var sortable = new ...

    jQuery完全实例.rar

    elements (Element, Array&lt;Element&gt;) : 用于封装成jQuery对象的DOM元素 示例 设置页面背景色。 jQuery 代码: $(document.body).css( "background", "black" ); ----------------------------------------------...

    i-vector的工具箱

    In this example we plot the distribution (histogram) of (first cepstral coefficient) in a sample feature file, before and after windowed CMVN: &gt;&gt; load('mfcc') &gt;&gt; size(mfcc) ans = 39 24252 &gt;&gt;...

    ImpREC 1.7c

    function in the thunk and will get its module name. =&gt; Much faster when editing each function by hand. - Improved 'Exact Call' (It will not retrace all exact calls from a slot if they have ...

    网页制作完全手册

    The first a element in this example does not work properly. Without the return in the onclick燡Script expression, the browser interprets the function expression, throws away the resulting value, and ...

    LCTF软件备份VariSpec™ Liquid Crystal Tunable Filters

    The first of these is quite lengthy (30 seconds or more) because it involves measurements and exercising of the liquid crystal optics. The latter two are much faster but still can take a significant ...

    python3.6.5参考手册 chm

    PEP 471 - os.scandir() function – a better and faster directory iterator PEP 475: Retry system calls failing with EINTR PEP 479: Change StopIteration handling inside generators PEP 485: A function...

    ehlib_vcl_src_9_3.26

    elements-branches and itself be an element to other parental record. Component TDBGridEh supports to show the tree-type structure of these records. Allows to connect to the internal array of ...

    EhLib 9.1.024

    elements-branches and itself be an element to other parental record. Component TDBGridEh supports to show the tree-type structure of these records. Allows to connect to the internal array of ...

    2009 达内Unix学习笔记

    集合了 所有的 Unix命令大全 ...telnet 192.168.0.23 自己帐号 sd08077-you0 ftp工具 192.168.0.202 tools-toolss ... 各个 shell 可互相切换 ksh:$ sh:$ csh:guangzhou% bash:bash-3.00$ ... 命令和参数之间必需用空格隔...

    Git-2.21.0-64-bit.zip

    split "checking out a branch to work on advancing its history" and "checking out paths out of the index and/or a tree-ish to work on advancing the current history" out of the single "git checkout" ...

Global site tag (gtag.js) - Google Analytics