- Go - 错误处理
- Go - Interfaces
- Go - 类型转换
- Go - 递归
- Go - Maps
- Go - 范围
- Go - 切片
- Go - 结构
- Go - 指针
- Go - 数组
- Go - 字符串
- Go - 作用域
- Go - 函数
- Go - 循环
- Go - 条件判断
- Go - 操作符
- Go - 常量
- Go - 变量
- Go - 数据类型
- Go - 基本语法
- Go - 程序结构
- Go - 环境设置
- Go - 概述
- Go - Home
Go Useful Resources
Selected Reading
- Who is Who
- Computer Glossary
- HR Interview Questions
- Effective Resume Writing
- Questions and Answers
- UPSC IAS Exams Notes
Go - Decision Making
决策结构要求程序员指定一个或多个要由程序评估或测试的条件,以及如果条件被确定为真则要执行的一条或多条语句,如果条件被判定为假则可选地指定要执行的其他语句。
以下是大多数编程语言中常见的典型决策结构的一般形式
Go编程语言提供了以下类型的决策语句。单击以下链接以检查其详细信息。
Sr.No | Statement & Description |
---|---|
1 |
An if statement consists of a boolean expression followed by one or more statements. |
2 |
An if statement can be followed by an optional else statement, which executes when the boolean expression is false. |
3 |
You can use one if or else if statement inside another if or else if statement(s). |
4 |
A switch statement allows a variable to be tested for equapty against a pst of values. |
5 |
A select statement is similar to switch statement with difference that case statements refers to channel communications. |