首页
学习
活动
专区
圈层
工具
发布
    • 综合排序
    • 最热优先
    • 最新优先
    时间不限
  • 来自专栏C/C++基础

    Linux 命令(231)—— let 命令(builtin)

    3.选项说明 id++, id-- variable post-increment, post-decrement ++id, --id variable pre-increment

    66120编辑于 2022-12-25
  • 来自专栏tkokof 的技术,小趣及杂念

    编程小知识之 自增(自减)运算符

    pre-increment profile int index = 0; int value = 0; for (int i = 0; i < count; ++i) { value = ++index; } // post-increment

    1.3K20发布于 2019-10-30
  • 来自专栏小林coding

    冲进银行测开,扛住了!

    Result of pre-increment: " << result1 << std::endl; int result2 = i++; std::cout << "After post-increment : " << i << std::endl; std::cout << "Result of post-increment: " << result2 << std::endl; return 0; } 输出结果将是: Before increment: 0 After pre-increment: 1 Result of pre-increment: 1 After post-increment : 2 Result of post-increment: 1 可以看到,++i先将i的值加1,再返回加1后的值,而i++先返回i的当前值,再将i的值加1。

    51020编辑于 2023-08-22
  • 来自专栏鱼皮客栈

    冲进银行测开,扛住了!

    Result of pre-increment: " << result1 << std::endl; int result2 = i++; std::cout << "After post-increment : " << i << std::endl; std::cout << "Result of post-increment: " << result2 << std::endl; return 0; } 输出结果将是: Before increment: 0 After pre-increment: 1 Result of pre-increment: 1 After post-increment : 2 Result of post-increment: 1 可以看到,++i先将i的值加1,再返回加1后的值,而i++先返回i的当前值,再将i的值加1。

    50420编辑于 2023-09-06
  • 来自专栏米扑专栏

    函数指针和指针函数的学习小结

    operator Array access Member access from a pointer Member access from an object Scoping operator Post-increment

    1.4K20发布于 2019-02-19
  • 来自专栏全栈程序员必看

    Thinking in Java 系列 —(一)基本语法和操作

    System.out.println("++i : " + ++i); //2 Pre-increment 先增 System.out.println("i++ : " + i++); //2 Post-increment

    37120编辑于 2022-09-08
  • 来自专栏北京马哥教育

    Awk是什么?一文带运维小白快速掌握Linux Awk用法

    N/A -- lvalue Pre-decrement Numeric N/A lvalue ++ Post-increment

    2.7K60发布于 2018-05-04
  • 来自专栏JavaEdge

    Java8编程思想之Java异常机制最佳实践

    count = 0; public static void main(String[] args) { while(true) { try { // Post-increment

    1.4K20发布于 2021-02-22
  • 来自专栏JavaEdge

    Java异常机制的最佳实践

    count = 0; public static void main(String[] args) { while(true) { try { // Post-increment

    1.4K30编辑于 2022-11-30
领券