热门

最新

红包

立Flag

投票

同城

我的

发布
sdddlll
愚公要移山
5 年前
truesdddlll

为什么Mongodb使用B树,而Mysql使用B+树?

为什么 MongoDB 索引选择B-树,而 Mysql 索引选择B+树(精干总结)

CSDN App 扫码分享
分享
评论
1
打赏
  • 复制链接
  • 举报
下一条:
求数组内两个数和等于数组内某一个数,输出两个数的下标#include<stdio.h>int main(){ int target,i,j,n; int nums[20]; printf("Enter the number of the nums:\n"); scanf("%d",&n); printf("Enter the nums:\n"); for(i=0;i<n;i++) scanf("%d",&nums[i]); printf("Enter the target:\n"); scanf("%d",&target); for(i=0;i<n;i++) for(j=i+1;j<n;j++) if(nums[i]+nums[j]==target) printf("%d %d",i,j); return 0;}
立即登录